Home >Operation and Maintenance >Linux Operation and Maintenance >Usage of linux compressed file command zip
Windows systems use “.zip” format compressed files. In fact, “.zip” format files are a common compressed file type for both Windows and Linux systems. They belong to one of several mainstream compression formats (zip, rar, etc.). It is a fairly simple storage format that compresses each file separately.
Usage of linux compressed file command zip
zip [选项] 压缩包名 源文件或源目录列表
Options:
Option | Meaning |
Recursively compress directories, and Compress all files and subdirectories in the specified directory. | |
After compressing the file, deleting the original file is equivalent to moving the file into the compressed file. | |
Display detailed compression process information. | |
Do not display the command execution process during compression. | |
The compression level is a number from 1 to 9, -1 means faster compression, and -9 means better compression. | |
Update the compressed file, that is, add new files to the compressed file. |
zip ana.zip anaconda-ks.cfg2. Compress multiple files
zip test.zip install.log install.log.syslog3. Compressed folder
zip -r dir1.zip dir1(Online video tutorial sharing:
linux video tutorial)
The above is the detailed content of Usage of linux compressed file command zip. For more information, please follow other related articles on the PHP Chinese website!