Re: Here strings appends a newline

2015-02-22 Thread Stephane Chazelas
For the record, I beleive the <<< feature was introduced by the Unix port of rc (the plan9 shell) that did *not* add the trailing newline. zsh is the shell that brought that construct to the Bourne world and it did add the extra newline character. All of zsh, ksh, bash, yash add that newline. --

Re: Here strings appends a newline

2015-02-22 Thread Chet Ramey
On 2/22/15 1:30 PM, Håkon Hallingstad wrote: > I noticed that here strings (<<< word) doesn't quite follow the documented > behavior: "The result is supplied as a single string to the command on its > standard input." Instead, or in addition, a newline is appended to the > string. I therefore propo

Here strings appends a newline

2015-02-22 Thread Håkon Hallingstad
I noticed that here strings (<<< word) doesn't quite follow the documented behavior: "The result is supplied as a single string to the command on its standard input." Instead, or in addition, a newline is appended to the string. I therefore propose to clarify this in the man page, see below for pro