diff options
author | Graeme Coupar <grambo@grambo.me.uk> | 2012-08-17 16:58:35 +0100 |
---|---|---|
committer | Graeme Coupar <grambo@grambo.me.uk> | 2012-08-17 17:13:09 +0100 |
commit | d3f6507a2e432efe48a3b8ac8f45c32e7d2ab656 (patch) | |
tree | b061a36041a5ae3123311a755c293e18af7e6041 /plugins/debian/debian.plugin.zsh | |
parent | d05b2010ffd4cd33ff9402c402051b1caf985d97 (diff) | |
download | zsh-d3f6507a2e432efe48a3b8ac8f45c32e7d2ab656.tar.gz zsh-d3f6507a2e432efe48a3b8ac8f45c32e7d2ab656.tar.bz2 zsh-d3f6507a2e432efe48a3b8ac8f45c32e7d2ab656.zip |
Debian plugin now pipes which stderr to stdout
The debian plugin calls which to determine whether aptitude & sudo are
installed. However, if these are not installed then the error output
from which will be output. Since this isn't really an error condition,
this commit updates the which calls to pipe stderr to stdout, thus
hiding the error messages.
Diffstat (limited to 'plugins/debian/debian.plugin.zsh')
-rw-r--r-- | plugins/debian/debian.plugin.zsh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/debian/debian.plugin.zsh b/plugins/debian/debian.plugin.zsh index 39d3ef36a..da86b1711 100644 --- a/plugins/debian/debian.plugin.zsh +++ b/plugins/debian/debian.plugin.zsh @@ -6,14 +6,14 @@ # Use aptitude if installed, or apt-get if not. # You can just set apt_pref='apt-get' to override it. -if [[ -e $( which aptitude ) ]]; then +if [[ -e $( which aptitude 2>&1 ) ]]; then apt_pref='aptitude' else apt_pref='apt-get' fi # Use sudo by default if it's installed -if [[ -e $( which sudo ) ]]; then +if [[ -e $( which sudo 2>&1 ) ]]; then use_sudo=1 fi |