--- orig/etc/profile.d/bash-completion.sh 2006-01-18 19:28:45 +0300 +++ orig/etc/profile.d/bash-completion.sh 2006-06-01 16:00:11 +0400 @@ -1,7 +1,10 @@ -bash=${BASH_VERSION%.*}; bmajor=${bash%.*}; bminor=${bash#*.} -if [ "$PS1" ] && [ "$bmajor" -eq 2 ] && [ "$bminor" '>' 04 ] || [ $bmajor -gt 2 ] \ - && [ -f /etc/bash_completion ]; then # interactive shell - # Source completion code - . /etc/bash_completion +if [ "$PS1" ] && [ -f /etc/bash_completion ]; then + if [ ! -z "$SHELL" ] && [ "bash" == "${SHELL##*/}" ]; then + bash=${BASH_VERSION%.*}; bmajor=${bash%.*}; bminor=${bash#*.} + if [ "$bmajor" -eq 2 ] && [ "$bminor" '>' 04 ] || [ $bmajor -gt 2 ]; then # interactive shell + # Source completion code + . /etc/bash_completion + fi + unset bash bmajor bminor + fi fi -unset bash bmajor bminor