I have several commands with channels, for example:
find [options] | grep [options] | xargs grep [options]
Each of them can potentially create errors (permission errors, space errors in file names, etc.) that do not interest me. So I want to redirect all errors to / dev / null. I know that I can do this with help 2>/dev/null, for each team . Can I reassign I / O redirection? Ideally, I would just install it once, at the beginning / end of the command, and then it would affect all subsequent / previous commands. Alternatively, can I redirect the I / O redirection so that it continues to affect all commands until it is reset?
I use bash (I checked the man page for bash built-in functions and did not see the '>' and '<' characters at the top, so I assumed it was a Linux thing ... sorry)
source
share