I have placed my comments among yours, I hope you don't mind. On Mon, Apr 15, 2019 at 07:19:14AM +1000, Cameron Simpson wrote: > On 14Apr2019 20:06, felixs <besteck...@gmail.com> wrote: > > fiddling with sed in the mutt mailing bash script > > Nothing you're doing requires bash. Just use /bin/sh - "the shell" - it is > portable; it _is_ bash on many linux systems (though by no means all), and > it is _always_ present on any POSIX system. You're writing Bourne shell > scripts, not GNU's particular dialect.
Thanks for your view on the matter. Personally speaking, I'm writing shell scripts to my own discretion and I like bash, and I appreciate the GNU project. I might write a .sh AND a .bash version ... whenever I like to. As the op has been served by other list members, there's no need to hurry. > > > I am writing I do not find > > a way to make sed read all files of a directory from standard in? > > I redirected standard input to a file and try to 'point' sed to all the > > files of the directory which is the spoolfile (maildir), like so: > > (...) > So invoke sed many times: > > for spoolfile in path/to/spooldir/* > do > sed ..... < "$spoolfile" > done Ok, thanks. > > I searched in the documentation of sed (info sed) > > The documentation should be in "man sed". But the GNU folks like to reader > than fairly useless and shove the useful stuff sideways. Aha, didn't notice it, but will take note of that. > > Regardless, redirection is part of the shell, and not part of sed, so what > you want won't be there (unless there's some example that just happens to > match what you're trying to do). > > Have a read of "man sh". Everything is in there, in one place. I like the manpages, too, but info sed seemed much more complete and instructive. First of all I read and still do read the Bash Reference Manual, it's all in there. Thanks, I know that redirection is part of the shell, but I was and I still am interested in sed. Cheers, felixs