当前位置:网站首页>Compression and decompression commands
Compression and decompression commands
2022-06-28 19:51:00 【Bio dinosaur】
Linux Basic commands
1.1 Compression and decompression commands
Catalog
One 、zip
zip The function of the command is to compress files , The decompression command is unzip. adopt zip The command can package files into .zip Compressed package of format , It will contain the name of the file 、 route 、 Creation time 、 Last modification time and other information .
Use format :
zip [ Options ] Package name Source file or source directory list
Common parameters :
| Parameters | significance |
|---|---|
| -r | Recursively compress directories , All files and subdirectories under the directory will be compressed . |
| -m | After compressing the file , Delete the original file , It's equivalent to moving a file into a compressed file . |
| -v | Display detailed compression process information . |
| -q | The execution process of the command is not displayed during compression . |
| -z | Annotate the compressed file |
| -u | Update compressed file , That is, add a new file to the compressed file . |
| -d | Update the files in the compressed package |
| -n< The ending string > | Do not compress files with a specific suffix string |
| - Compression level | The compression level is from 1~9 The number of ,-1 Represents faster compression ,-9 Represents better compression . |
for example , Press the following files into a package :
train.txt train1.txt train2.txt
zip train.txt.zip *.txt
give the result as follows :
train.txt train.txt.zip train1.txt train2.txt
decompression zip file , First delete the previously compressed files , Then decompress , give the result as follows :
rm *.txt
unzip train.txt.zip
ls
train.txt train.txt.zip train1.txt train2.txt
Two 、gzip
gzip Is a widely used compression program , After it compresses the file , There will be many places after its name “.gz” Extension .
Use format :
gzip [ Option parameters ][-s < Compress suffix strings >] [ file / Catalog ]
Common parameters :
| Parameters | significance |
|---|---|
| -d | Unpack the compressed file |
| -v | Display during execution of instructions |
| -l | List information about compressed files |
| -r | Recursive processing , Process all files and subdirectories under the specified directory |
| -A | Add files to an existing backup file |
| -B | Set block size |
| -c | Output the extracted file to the standard output device |
for example , Press the following files into a package :
train.txt train1.txt train2.txt
gzip *.txt
give the result as follows :
train.txt.gz train1.txt.gz train2.txt.gz
decompression :
gzip -d *.gz
ls
train.txt train1.txt train2.txt
summary
Compression and decompression tools zip and gzip Usage of
边栏推荐
- 颜色渐变的FontAwesome图标
- C语言局部变量与全局变量重名时的优先级问题(当局部变量和全局变量同时存在的时候,优先引用局部变量,而不去引用全局变量)
- Variable autoencoders (vaes)
- Chunfeng power and Huawei work together to build a smart Park benchmark, and the future factory innovation will reach a new level
- Huawei cloud onemeeting tells you that the whole scene meeting is held like this!
- 严重性 代码 说明 项目 文件 行 禁止显示状态 错误 C1047 对象或库文件“.lib”是使用与其他对象(如“x64\Release\main.obj”)不同的
- Ali open source (easyexcel)
- return new int[]{i + 1, mid + 1}; return {i + 1, mid + 1};
- The amazing nanopc-t4 (rk3399) is used as the initial configuration and related applications of the workstation
- Tencent tangdaosheng: facing the new world of digital and real integration, developers are the most important "architects"
猜你喜欢

Autumn recruitment experience sharing | how to prepare for bank interview
![return new int[]{i + 1, mid + 1};return {i + 1, mid + 1};](/img/6a/45a4494276deba72ef9833818229f5.png)
return new int[]{i + 1, mid + 1};return {i + 1, mid + 1};

Nanopc-t4 (rk3399) Game1 OLED (I2C) display time weather temperature

Group programming TIANTI competition exercise - continuously updating

Xiaobai's e-commerce business is very important to choose the right mall system!

Markdown mermaid种草(1)_ mermaid简介

30讲 线性代数 第四讲 线性方程组

机器学习笔记 temperature+Softmax

严重性 代码 说明 项目 文件 行 禁止显示状态 错误 C1047 对象或库文件“.lib”是使用与其他对象(如“x64\Release\main.obj”)不同的
![return new int[]{i + 1, mid + 1}; return {i + 1, mid + 1};](/img/6a/45a4494276deba72ef9833818229f5.png)
return new int[]{i + 1, mid + 1}; return {i + 1, mid + 1};
随机推荐
裁员真能拯救中国互联网?
Machine learning notes temperature+softmax
1002_20181019
基于趋势和季节性的时间序列预测
Average score of 100 people
bluecmsv1.6代码审计
Markdown Mermaid planting grass (1)_ Introduction to Mermaid
Can only one task be submitted by one table if the flinkcdc is submitted by flinksql? When there are thousands of watches
图神经网络入门 (GNN, GCN)
Kaggle腸胃道圖像分割比賽baseline
阿里开源(EasyExcel)
Analysys analytics' 2022 China Banking privacy computing platform supplier strength matrix analysis' research activity was officially launched
List adding timer (positive and countdown)
2022年4月10日--使用C#迈出第一步--使用C#从.NET类库调用方法(没看懂)
jsp中获取session中的值
Demo of intelligent computing system 2 bangc operator development (heterogeneous programming flow of CPU and mlu270)
《数据安全法》出台一周年,看哪四大变化来袭?
2342
QSP read label configuration error
智能计算系统1 环境搭建