[Bash-completion-commits] [SCM] bash-completion branch, master, updated. 1.3-365-g2a05603

David Paleino dapal at debian.org
Tue Jun 14 19:31:19 UTC 2011


The following commit has been merged in the master branch:
commit 2a05603ecd4af35d88b1f91c963d1ee7aaf1749e
Author: David Paleino <dapal at debian.org>
Date:   Tue Jun 14 21:31:02 2011 +0200

    Implemented a blacklist for unwanted third-parties completions

diff --git a/bash_completion b/bash_completion
index 1d34b16..53f6264 100644
--- a/bash_completion
+++ b/bash_completion
@@ -42,6 +42,10 @@ fi
 [ -n "$BASH_COMPLETION_COMPAT_DIR" ] || BASH_COMPLETION_COMPAT_DIR=/etc/bash_completion.d
 readonly BASH_COMPLETION_COMPAT_DIR
 
+# Blacklisted completions, causing problems with our code.
+#
+_blacklist_glob='@(acroread.sh)'
+
 # Set a couple of useful vars
 #
 UNAME=$( uname -s )
@@ -1803,7 +1807,7 @@ if [[ -d $BASH_COMPLETION_COMPAT_DIR && -r $BASH_COMPLETION_COMPAT_DIR && \
     -x $BASH_COMPLETION_COMPAT_DIR ]]; then
     for i in $(LC_ALL=C command ls "$BASH_COMPLETION_COMPAT_DIR"); do
         i=$BASH_COMPLETION_COMPAT_DIR/$i
-        [[ ${i##*/} != @($_backup_glob|Makefile*) \
+        [[ ${i##*/} != @($_backup_glob|Makefile*|$_blacklist_glob) \
             && -f $i && -r $i ]] && . "$i"
     done
 fi
@@ -1812,7 +1816,7 @@ if [[ "${BASH_SOURCE[0]%/*}/completions" != $BASH_COMPLETION_COMPAT_DIR && \
     -x "${BASH_SOURCE[0]%/*}/completions" ]]; then
     for i in $(LC_ALL=C command ls "${BASH_SOURCE[0]%/*}/completions"); do
         i="${BASH_SOURCE[0]%/*}/completions/$i"
-        [[ ${i##*/} != @($_backup_glob|Makefile*) \
+        [[ ${i##*/} != @($_backup_glob|Makefile*|$_blacklist_glob) \
             && -f $i && -r $i ]] && . "$i"
     done
 fi

-- 
bash-completion



More information about the Bash-completion-commits mailing list