Re: Heads up: gtar gone from base system

From: Brian K. White <brian_at_aljex.com>
Date: Tue, 29 Mar 2005 01:56:14 -0500
----- Original Message ----- 
From: "Peter Jeremy" <PeterJeremy_at_optushome.com.au>
To: "Brian K. White" <brian_at_aljex.com>; <freebsd-current_at_FreeBSD.ORG>
Sent: Tuesday, March 29, 2005 1:25 AM
Subject: Re: Heads up: gtar gone from base system


> On Mon, 2005-Mar-28 23:15:27 -0500, David Schultz wrote:
>>On Mon, Mar 28, 2005, Brian K. White wrote:
>>> >    To move file hierarchies, use a command line like this:
>>> >
>>> >    tar -cf - -C srcdir . | tar xpf - -C destdir
>>>
>>> Why not?
>>> Isn't that just a slight convenience for this?:
>>> cd srcdir ; tar cf - . |( cd destdir ; tar xpf - )
>>
>>detsdir: No such file or directory.
>
> Brian missed a pair of parenthenis.  The example should read:
>
> ( cd srcdir ; tar cf - . ) | ( cd destdir ; tar xpf - )

All the first perens does is leave you sitting wherever you were before 
starting, whereas my example would have left you sitting in srcdir.
It makes no functional difference in the tar/untar job itself.

In truth, my example was from something I do all the time on SCO and is in 
sco's tar man page but it's such basic shell and tar usage that it works the 
same everywhere. I do it on Linux and FreeBSD too and I just verified on a 
5.3 box just to make sure instead of relying on memory and common sense.

Brian K. White  --  brian_at_aljex.com  --  http://www.aljex.com/bkw/
+++++[>+++[>+++++>+++++++<<-]<-]>>+.>.+++++.+++++++.-.[>+<---]>++.
filePro BBx  Linux SCO  Prosper/FACTS AutoCAD  #callahans Satriani
Received on Tue Mar 29 2005 - 04:56:45 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:30 UTC