From: Iain Patterson Date: Mon, 15 Aug 2005 16:02:44 +0000 (+0000) Subject: Redirect stderr when finding files. X-Git-Url: http://git.iain.cx/?a=commitdiff_plain;h=a7ded21407292fd479e8eedd8d9f640d5f386a06;p=profile.git Redirect stderr when finding files. git-svn-id: https://svn.cambridge.iain.cx/profile/trunk@3 6be0d1a5-5cfe-0310-89b6-964be062b18b --- diff --git a/.profile.d/completion.bashrc b/.profile.d/completion.bashrc index ad072bf..68b1c9d 100644 --- a/.profile.d/completion.bashrc +++ b/.profile.d/completion.bashrc @@ -10,7 +10,7 @@ function _generic_completion() { COMPREPLY=() cur=${COMP_WORDS[COMP_CWORD]} - HOSTS="$(find $COMPLETION_DIR -type f -perm -100 | sed 's@.*/@@')" + HOSTS="$(find $COMPLETION_DIR -type f -perm -100 2>/dev/null | sed 's@.*/@@')" COMPREPLY=($(compgen -W "$HOSTS" -- "$cur")) return 0 @@ -30,7 +30,7 @@ function _process() { function _pid() { cur=${COMP_WORDS[COMP_CWORD]} - PROCESSES="$(find /proc -name '[0-9]*' -maxdepth 1 | sed 's@.*/@@')" + PROCESSES="$(find /proc -name '[0-9]*' -maxdepth 1 2>/dev/null | sed 's@.*/@@')" COMPREPLY=($(compgen -W "$PROCESSES" -- "$cur")) return 0