tar
e[x]tract
[z]is
[f]ile
[v]erbosely
archive.tar.gz
--directory=archivedir
For creation it’s pretty much the same but you need to specify [c]reate, e.g. tar czvf archive.tar.gz filestoarchive/ and for lis[t]ing it’s - tar tf archive.tar.gz
That mnemonic is misleading if it’s not gzipped, and unless you’re untarring a stream from a pipe or over a network, you don’t need to tell tar what compression was used when extracting, it knows.
It’s pretty simple
tar e[x]tract [z]is [f]ile [v]erbosely archive.tar.gz --directory=archivedirFor creation it’s pretty much the same but you need to specify [c]reate, e.g.
tar czvf archive.tar.gz filestoarchive/and for lis[t]ing it’s -tar tf archive.tar.gztar [t]he [f]uck am_i_looking_at.tar.gzv stands for “vocking”, tar -xzvf is the intended use
Tar -xf doodoobutt.tar
it that simple.
zis?
That mnemonic is misleading if it’s not gzipped, and unless you’re untarring a stream from a pipe or over a network, you don’t need to tell
tarwhat compression was used when extracting, it knows.True, it’s just easy to remember.