From: rjorgenson Date: Wed, 30 Nov 2011 06:45:25 +0000 (-0700) Subject: added error suppression to tree alias X-Git-Url: https://source.supwisdom.com/gerrit/gitweb?a=commitdiff_plain;h=f0bceecb88f01a143c9d4df977c9db473e8618bb;p=common%2Fbash_it.git added error suppression to tree alias the $(which tree) check general.aliases would ouput an error if the command was not found. Added suppression of that error. --- diff --git a/aliases/available/general.aliases.bash b/aliases/available/general.aliases.bash index cfd456f..6c722f4 100644 --- a/aliases/available/general.aliases.bash +++ b/aliases/available/general.aliases.bash @@ -46,7 +46,7 @@ alias -- -="cd -" # Go back alias h='history' # Tree -if [ ! -x "$(which tree)" ] +if [ ! -x "$(which tree 2>/dev/null)" ] then alias tree="find . -print | sed -e 's;[^/]*/;|____;g;s;____|; |;g'" fi