Thursday, October 7, 2010

7-Zip command line

Download and install 7-Zip.
http://www.7-zip.org/

7z.exe a c:\a.7z "C:\Program Files"
compresses "C:\Program Files" completely, including all subfolders.

 7z a  c:\a.zip c:\dir\*.txt
compresses all files wih extension txt

7z.exe a c:\a.7z c:\file1.txt d:\dir2\file2.txt
compress multiple files at different locations
7z.exe e c:\test\archive.zip
extract all files to the current location

7z.exe e c:\test\archive.zip -oc:\test\AllFiles
extract all files to the specified path i.e. c:\test\AllFiles

No comments:

Post a Comment