[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
How can redirection operator aka ">" open output in append instead of or
How can redirection operator aka ">" open output in append instead of ordinary write mode?
Thu, 16 May 2019 20:25:21 +0000
Hi. Would bash devs even consider replacing the current behaviour of ">"
(redirection) to do the equivalent of the following(under the hood) ?
`command > $somewhere`
then actually do(under the hood):
: > $somewhere
command >> $somewhere
ie. create&truncate file, then open it in append mode and redirect to it,
instead of what it currently does(aka not append).
So, it would be functionally the same except that it would help mitigate some
cases where output would get overwritten.
For context: https://stackoverflow.com/q/56167779/11509478
If not, could the devs(or anyone) please suggest a place in the source code
where to look for attempting to implement/change this for myself?
publickey - email@example.com - 0x947B9B34.asc
Description: OpenPGP digital signature
- How can redirection operator aka ">" open output in append instead of ordinary write mode?,