[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Trailing newlines disappear
From: |
Chet Ramey |
Subject: |
Re: Trailing newlines disappear |
Date: |
Tue, 13 Jun 2017 16:52:30 -0400 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 |
On 6/12/17 8:55 PM, Peter & Kelly Passchier wrote:
> On 13/06/2560 02:54, Chet Ramey wrote:
>> If you want to effectively change it to a newline, specify NUL as the
>> line delimiter using the -d option (new in bash-4.4).
>
> Thanks, that sounds like a clean solution!
> I only reverted to mapfile because $(...) command substitution could not
> be made to work. (I still have to 'convert' the array to a normal
> variable in the next step...). Would a shell option for command
> substitution using NUL be a desirable feature to bash users??
You mean command substitution cutting off the input it reads at the
occurrence of a NUL?
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU chet@case.edu http://cnswww.cns.cwru.edu/~chet/
- Re: Trailing newlines disappear, (continued)
- Re: Trailing newlines disappear, Chet Ramey, 2017/06/09
- Re: Trailing newlines disappear, L A Walsh, 2017/06/09
- Re: Trailing newlines disappear, Peter & Kelly Passchier, 2017/06/09
- Re: Trailing newlines disappear, Pierre Gaston, 2017/06/09
- Re: Trailing newlines disappear, Greg Wooledge, 2017/06/09
- Storing NUL in variables, George, 2017/06/09
- Re: Storing NUL in variables, Pierre Gaston, 2017/06/10
- Re: Storing NUL in variables, George, 2017/06/11
- Re: Trailing newlines disappear, Chet Ramey, 2017/06/12
- Re: Trailing newlines disappear, Peter & Kelly Passchier, 2017/06/12
- Re: Trailing newlines disappear,
Chet Ramey <=
- Re: Trailing newlines disappear, Peter & Kelly Passchier, 2017/06/13
- Re: Trailing newlines disappear, PePa, 2017/06/09