📅  最后修改于: 2022-03-11 14:51:08.094000             🧑  作者: Mango
tar -czvf name-of-archive.tar.gz /path/to/directory-or-file
#-c: Create an archive.
#-z: Compress the archive with gzip.
#-v: Display progress in the terminal while creating the archive, also known as “verbose” mode. The v is always optional in these commands, but it’s helpful.
#-f: Allows you to specify the filename of the archive.
#-x : Extract the archive
#-t : displays or lists files in archived file
#-u : archives and adds to an existing archive file
#-A : Concatenates the archive files
#-j : filter archive tar file using tbzip
#-W : Verify a archive file
#-r : update or add file or directory in already existed .tar file