Re: [9fans] dup(3)

2009-10-19 Thread hugo rivera
Thanks for your feedback. -- Hugo

Re: [9fans] dup(3)

2009-10-16 Thread Steve Simon
> @{builtin cd $1 && tar cf /fd/1 .} | @{builtin cd $2 && tar xTf /fd/0} the /fd/1 and /fd/0 fererences ensure that dircp will work with ape's tar which doesn't read/write stdin/stdout by default like plan9's does. -Steve

Re: [9fans] dup(3)

2009-10-16 Thread Russ Cox
On Fri, Oct 16, 2009 at 8:58 AM, hugo rivera wrote: > I am having a hard time understanding the dircp script and the dup(3) > device. What's exactly the purpose of writing > @{builtin cd $1 && tar cf /fd/1 .} | @{builtin cd $2 && tar xTf /fd/0} > instead of > {builtin cd $1 && tar c .} | {builtin

Re: [9fans] dup(3)

2009-10-16 Thread erik quanstrom
> @{builtin cd $1 && tar cf /fd/1 .} | @{builtin cd $2 && tar xTf /fd/0} > instead of > {builtin cd $1 && tar c .} | {builtin cd $2 && tar xT} consider, ; one=/bin; two=/tmp; cd / ; @{builtin cd $one} | @{builtin cd $two} ; pwd / ; {builtin cd $one} | {builtin cd $t