On 8/4/2019 21:19, Robert Elz wrote: > In general here docs (and here strings) are overused - it is always > possible to simply write a pipe instead
What is nice about here docs/strings is that there are no subshells involved. I think Linda's main drive is to seek improvement in how bash works. Now that lack of memory is in no way a constraint for the vast majority of situations where bash is commonly used, it would be great if that memory could be used instead of writing to a file system -- whether a pipe, a here doc/string does that, or explicitly through redirection. Things could work without requiring the presence of a file system. > Some do, actually - in fact, I think all do, they start off with > no memory allocated, and grab more as data is written. But they > all have a limit on how much they will buffer for one pipe, otherwise > one stupid process could clog the system for everyone (having no > available memory/swap is a much worse situation than a filesystem > simply being full.) If temporary files are not created in all cases of here docs/strings, it would be great if the buffer size that bash allocates could be set. Bash not writing temporary files for here strings & docs would be a great feature to me. Peter