tar -xvf file.tar.gz
# compress
tar -czvf projects.tar.gz projects/
# extract
tar -xzvf projects.tar.gz
-c, --create
create a new archive
-x, --extract, --get
extract files from an archive
-z, --gzip, --gunzip --ungzip
-v, --verbose
verbosely list files processed
-f, --file ARCHIVE
use archive file or device ARCHIVE
tar [-] A --catenate --concatenate | c --create | d --diff --compare | --delete | r --append | t --list |
--test-label | u --update | x --extract --get [options] [pathname ...]
tar -zxvf file_name.tar.gz
tar -xzf file.tar.gz
tar -xzvf archive.tar.gz
# compress
tar czvf < archive_name >.tar.gz < path >
# extract
tar xzvf < archive_name >.tar.gz
tar xzvf < archive_name >.tar.gz -C /home/usera/tmp
tar -xvzf community_images.tar.gz
tar -xf archive.tar.gz
The docs tell us that None is returned by extractfile() if the member is a not a regular file or link.
One possible solution is to skip over the None results:
tar = tarfile.open("filename.tar.gz", "r:gz")
for member in tar.getmembers():
f = tar.extractfile(member)
if f is not None:
content = f.read()
tar –xvzf documents.tar.gz
tar -xvf archive.tar.gz
or
tar -xf archive.tar.gz -C /home/linuxize/files
tar -xf archive.tar.gz
tar -zxvf {file.tar.gz}
tar -xf archive.tar.gz -C /home/linuxize/files
tar -xvzf community_images.tar.gz
1. Extract it all
2. Come to the folder in which you extracted it
3. ./(filename)
4. make
5. sudo make install
tar -czvf projects.tar.gz $HOME/projects/
tar –xvf documents.tar
gunzip.exe example.tar.gz
tar.exe xf example.tar
tar -xzf archive-name.tar.gz
cd archive-name
./configure
make
sudo make install