Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: bug in zsh-2.6-beta21
- X-seq: zsh-users 260
- From: Zoltan Hidvegi <hzoli@xxxxxxxxxx>
- To: vlefevre@xxxxxxxxxxx
- Subject: Re: bug in zsh-2.6-beta21
- Date: Tue, 25 Jun 1996 21:11:56 +0200 (MET DST)
- Cc: zsh-users@xxxxxxxxxxxxxxx
- In-reply-to: <199606251855.UAA03602@xxxxxxxxxxxxxxxxxxxxx> from Vincent Lefevre at "Jun 25, 96 08:55:26 pm"
- Organization: Dept. of Comp. Sci., Eotvos University, Budapest, Hungary
- Phone: (36 1)2669833 ext: 2667, home phone: (36 1) 2752368
Vincent Lefevre wrote:
> [...] But under zsh 2.6-beta21:
>
> $ var=`echo "ab\ncd\nef"`
> $ echo $var
> ab
> cd
> ef
> $ var=`echo "ab\ncd\nef\n"`
> $ echo $var
> ab
> cd
> ef
> $
>
> The last "\n" is not printed.
All other shells strip trailing newlines from command substitution and
POSIX requires this behaviour. So far zsh stripped only one trailing
newline now it strips all. But if the opposition of this change is big
enough I may change it back. I thought that this change will be mostly
unnoticeable and I hope that it won't break any scripts.
Zoltan
Messages sorted by:
Reverse Date,
Date,
Thread,
Author