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 the
我们再linux中常见的压缩文件有.tar.gz,.zip,.gz,在linux中,你要习惯没有.rar的日子. 一下为tar,zip命令详解 tar -zcvf /home/files.tar.gz /files tar -zcvf 打包后生成的文件名全路径 要打包的目录 例子:把/files文件夹打包后生成一个/home/files.tar.gz的文件. zip 压缩方法: 压缩当前的文件夹 zip -r ./files.zip ./* -r表示递归 zip [参数] [打包后的文件名] [