Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: set -F kills read -t



# rayandrews@xxxxxxxxxxx / 2014-03-19 10:08:44 -0700:
> I thought I was expecting this to work:
> 
>       $ y () { echo "$1, $2, $3 "; }
> 
>       $ y one two three
>      one, two, three
> 
>      $ echo "one two three" | y
>      , ,                                                  << :-(

what would you expect to happen in

     $ echo "one two three" | y foo bar baz
 
> So grep is doing the 'switcheroo' here--going from reading arguments, to 
> reading stdin, and the pipe is the de facto 'stdin', and piped input
> does NOT become arguments :-)

  de facto?  stdin is stdin no matter what 'file' the descriptor names.

-- 
roman



Messages sorted by: Reverse Date, Date, Thread, Author