extracting tar files with absolute pathnames relatively
Earl H. Kinmonth
ked at garnet.berkeley.edu
Sun Apr 23 10:30:28 AEST 1989
In article <2620 at ssc-vax.UUCP> ray3rd at ssc-vax.UUCP (Ray E Saddler III) writes:
>In article <1501 at cfa205.cfa250.harvard.edu>, todd at cfa250.harvard.edu (Todd Karakashian) writes:
>> I am in posession of tapes containing tarfiles with absolute
>> pathnames. What I would like to do is to extract these files into a
>> different tree structure than they were tarred from. Thus, the
>> tarfile /usr/foo/file should go into the disk pathname /temp/file. I
>> have been unable to find a way to do this -- does anyone know how?
My version of GNU tar will do this very simply. It has a -Pnn option
where nn is the number of path elements to strip off. Although this
program was originally written to make tar archives under MSDOS, it will
also run under UNIX. I use it on a Sun for precisely the task you
describe.
pdtar is available from the author for non-commercial, non-military uses,
in SCO Xenix, Ultrix, BSD UNIX, and MSDOS versions.
Earl H. Kinmonth
History Department
University of California, Davis
916-752-1636 (voice, fax [2300-0800 PDT])
916-752-0776 secretary
ucbvax!ucdavis!ucdked!cck
More information about the Comp.unix.questions
mailing list