[Cialug] Random nerd fact

Todd Walton tdwalton at gmail.com
Thu Jul 26 13:14:58 UTC 2018


On Wed, Jul 25, 2018 at 7:47 PM, Kyle H <khamil8686 at gmail.com> wrote:

> |& redirects stdout and stderr of one command to the input of another?
> Alias for 2>&1 |
>
> Echo test |& less
> Echo test 2>&1 | less
>
> Just thought as interesting and helpful :)
>

Can be very useful! I usually go for the " 2>&1 | " style because I can
work it out in my head, the symbols are internally consistent, etc. It
trains me to remember the syntax of all that, which I still have to look up
once in a while.

--
Todd


More information about the Cialug mailing list