[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: extracting tarball to a location other than ./



Michael Marsh wrote:
On Tue, 29 Mar 2005 07:20:52 -0500, Matt Price <matt.price@utoronto.ca> wrote:
ok, I give up -- how do I tell tar to extract a tarball to a location
other than ./ ?  I 've been through the info pages but didn't notie
the solution in any of the obvious places.
I usually cd to the destination directory and worry about the path to
the tarfile:
$ cd src
$ tar xvf ../downloads/tarfile.tgz

Hi,

Markko's solution seems to be the answer to the specific question, but if I take it from where Michael stopped, and steer a bit offtopic, you might want to check the pushd/popd/dirs built-in commands in bash, which could be useful if you are scripting.

Andro

--
Andrey Andreev
University of Helsinki
Dept. of Computer Science



Reply to: