On Thursday, August 28, 2025, Kevin Pulo <kevin.p...@mongodb.com> wrote:
>
> I have a lot of control


Good. It's easier to change the input than change Bash and wait for another
release (which might take more than a year).


> I could instead force some special way of representing a blank line, eg.
> "<blank>", but then code which processes each word separately will need to
> be
> more complex than the current:
>
>     for word in $line; do
>         ...
>     done
>
> unless the "special blank line" is "one or more spaces/tabs".  But even
> then,
> care needs to be taken to ensure that a space gets output instead of a pure
> blank line.
>

It's hard to suggest a workaround without seeing the full picture but this
seems like your best bet. This or storing the input in a temporary file and
consuming it line by line instead of slurping it all at once.


-- 
Oğuz

Reply via email to