I. Zip format

  • Zip format:
Zip [-r] Compressed file name Source file or directoryCopy the code
  • Extract format:
Unzip Indicates the compressed file nameCopy the code

Note the difference in -r usage:

Two, GZ format:

– Compressed format:

– Decompressed format:

Ex. :

1, the source file disappeared :(d.txt disappeared)

2, keep the original folder (d.xt does not disappear)

use

3. Compress the directory

  • Gzip -r simply compresses the files inside the folder, not the folder:

Three, BZ2 format

  • The compression

  • unzip

Ex. :

  • Use -k to save the original file

  • Use -d to save compressed files

Fourth, the tar

  • packaging

  • Packaging solution

Five, the tar. Gz

  • Tar. gz package compression and decompression

Six, tar..bz2