Show all options
tar --help
Create Archive Of Specific Files
tar -vfcz outputfilename.gz inputfile1 inputfile2
Zipping Files And Directories
Use this to move to the directory containing the files and / or directories you want to zip
cd projects/myfolder
Zip 1 File
tar -vczf zip_output_filename.gz file_to_zip.a
Zip 2 Files
tar -vczf zip_output_filename.gz file_to_zip1.a file_to_zip2.a
Zip A File & 2 Directories
tar -vczf zip_output_filename.gz file_to_zip1.a directory_to_zip1 directory_to_zip2
"-vczf" are the options being used for the compress.
Unziping
tar zxvf zip_filename.gz
"zxvf" are the options being used and will cause an overwrite if any files already exist
Note that if a file was set as executable when zipped this permission will remain when it is unzipped whether overwriting an existing file or not.
Unzipping From Dropbox
See here.
