summaryrefslogtreecommitdiff
path: root/bash-completion/files/bash_completion.sh
diff options
context:
space:
mode:
authorChris Larson <clarson@kergoth.com>2004-11-09 00:36:47 +0000
committerChris Larson <clarson@kergoth.com>2004-11-09 00:36:47 +0000
commitf96441b9faf769c9ecdd4d338b605ea3d0cc4010 (patch)
treeedb17ec2c4ea13c5acb1c7350957a249a820e28d /bash-completion/files/bash_completion.sh
parentb6588aa6851fb220cedc387d21c51513ef8d67f4 (diff)
Disable bk EOLN_NATIVE conversions on all files in packages FILESPATHs, to prevent it screwing up patches.
BKrev: 4190111fA4MuVozAqwE7xOSL9fr-TA
Diffstat (limited to 'bash-completion/files/bash_completion.sh')
-rw-r--r--bash-completion/files/bash_completion.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/bash-completion/files/bash_completion.sh b/bash-completion/files/bash_completion.sh
index e69de29bb2..09715211c0 100644
--- a/bash-completion/files/bash_completion.sh
+++ b/bash-completion/files/bash_completion.sh
@@ -0,0 +1,12 @@
+# check for bash
+[ -z "$BASH_VERSION" ] && return
+
+bash=${BASH_VERSION%.*}; bmajor=${bash%.*}; bminor=${bash#*.}
+if [ "$PS1" ] && [ $bmajor -eq 2 ] && [ $bminor '>' 04 ] \
+ && [ -f /etc/bash_completion ]; then # interactive shell
+ # Source completion code
+ . /etc/bash_completion
+fi
+
+unset bash bmajor bminor
+