Unzip command unzip common method summary

Unzip command unzip common methods Summary:

1, extract the files to the current directory

1
unzip pythontab.com.zip

2, if we want to extract the files to a specified directory, need to use the -d parameter.

1
unzip -d . /tmp/  pythontab.com.zip

3, decompression time, and sometimes do not want to overwrite the existing file, then you can add the parameter -n

1
2
unzip -n pythontab.com.zip
unzip -n -d . /tmp/  pythontab.com.zip

4, just look at what a zip file included in the package, not decompress

1
unzip -l pythontab.com.zip

5. Review the displayed list of files also contain compression ratio

1
unzip - v  pythontab.com.zip

6. Check the zip file is damaged

1
unzip -t pythontab.com.zip

7, decompress the compressed files pythontab.com.zip in the specified directory tmp, if the same file already exists, requires unzip command to overwrite the original file

1
unzip -o pythontab.com.zip -d . /tmp

Guess you like

Origin www.cnblogs.com/cheyunhua/p/11267876.html