News for hackers. Stuff that matters.
Re:Stupid Unix Tricks by lloeki on Saturday October 19, 2019 @05:01AM (#21297546)
type -p also works in bash/zsh
Re:Stupid Unix Tricks by Fnoord on Saturday October 19, 2019 @05:44AM (#21297659)
Fish as well, but the redirection of both stdout and stderr is different:

  type -p brew >/dev/null ^&1; and brew
in Bash it would be:

  type -p brew &>/dev/null && brew
Using test avoids caring about stdout/stderr.