unpacking one single file from archive

C. Linus Hicks lhicks at nc.rr.com
Thu Jan 20 00:44:44 UTC 2005


On Wed, 2005-01-19 at 07:04 -0600, Rigler, Stephen C. wrote:
> If the archive, "x.tar.gz", has a file that you want called "z.doc"
> then if you only want to extract the one file do:
> 
> tar xvzf x.tar.gz z.doc

This is true, AND you must match the path as stored in the archive. So
for example, if you have an archive with:

xyz/1.abc

Then you must use:

tar xf x.tar xyz/1.abc

-- 
C. Linus Hicks <lhicks at nc dot rr dot com>




More information about the redhat-list mailing list