Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Lonely spacecowboy
Brian K. White <brian@xxxxxxxxx>:
> Stephane Chazelas <Stephane_Chazelas@xxxxxxxx>:
> >On Tue, Mar 27, 2007 at 03:01:42PM -0400, Brian K. White wrote:
[...]
> >>The difference is "|read" creates a child process that read runs in, and
> >>any env variables set in that child process are not visible from the
> >>parent, and the while-do-done command (and all commands in that loop) ar
> >>running in the parent.
> >
> >While this is true for bash and pdksh it's not true for zsh:
> >
> >~$ echo foo | read
> >~$ echo $REPLY
> >foo
[...]
> It doesn't work in one enviroment I use zsh a lot in.
>
> $P$Gecho this is a test |read aa bb cc
> $P$Gecho $aa $bb $cc
>
> $P$G
>
> This is latest freestanding (static binary not needing cygwin dll) version
> of zsh for windows that I have been able to locate, which is quite old,
> $P$Gecho $VERSION
> 3.0.5.001
> $P$G
Hm, I don't know about the specifics of the native windows port of
zsh. But AFAIK, zsh versions v3 and above do not set $VERSION but
$ZSH_VERSION. I tried the above on a linux v2.6 system:
[snip]
zsh% echo this is a test |read aa bb cc
zsh% echo $aa $bb $cc
this is a test
zsh% echo $ZSH_VERSION
3.0.4
zsh% echo $VERSION
[snap]
I don't know if the technique used to make this possible on unixoid
systems is not applicable on windows systems.
Regards, Frank
--
In protocol design, perfection has been reached not when there is
nothing left to add, but when there is nothing left to take away.
-- RFC 1925
Messages sorted by:
Reverse Date,
Date,
Thread,
Author