Originally posted by rahulsundaram
for .gz files
tar cxvf packagename.tar.gz
Umm, I'm pretty sure that for tar.gz files you go
See 'tar --help' for more info.
Also it's useful to remember that what you're actually doing is decompressing the tar file, and THEN unpacking the tar file.
If you see a file like readme.txt.bz2 then it's probably a text file that has been bzipped (not packed into a tar file). So in this case you decompress the file by going
bzip2 -d readme.txt.bz2 which will leave you with readme.txt (readme.txt.bz2 will be gone).