5/6/2015 - 5:59 AM

Compress and uncompress files and folders [ZIP, TAR]

ZIP – Cross Platform

To compress

zip -r folder_to_compress

To extract


If you want to make a zip without those invisible Mac resource files such as “_MACOSX” or “._Filename” and .ds store files, use the “-X” option in the command so:

zip -r -X folder_to_compress

TAR.GZ – Cross Platform

To compress

tar -zcvf archive_name.tar.gz folder_to_compress

To extract

tar -zxvf archive_name.tar.gz