Re: Gnu Tar: Extracting files into a single directory
Dubious Dude <[email protected]>
| Newsgroups | gmane.comp.gnu.utils |
|---|---|
| Organization | Suspicious Bystanders Incorporated (SBI) |
| Message-ID | <[email protected]> |
Sven Mascheck wrote: > Dubious wrote: > >> tar.gz archive. I want to extract them all into a single directory, >> regardless of their path in the archive. > > $ zcat archive.tar.gz | pax > ./ > ./dir/ > ./dir/subdir/ > ./dir/subdir/b > ./dir/subdir/a > ./dir/a > > $ zcat archive.tar.gz | pax -r -s ',.*/,,p' > ./ >> > ./dir/ >> > ./dir/subdir/ >> > ./dir/subdir/b >> b > ./dir/subdir/a >> a > ./dir/a >> a > > $ ls > a b Thank you, Sven. I'll keep that in mind for when pax is available. I know from the cygwin mailing list that this is possible, even through it doesn't come with cygwin itself.