From 1702bd2d4c034f5c3e0e63ab3a37081ab123eacb Mon Sep 17 00:00:00 2001 From: Adar Nimrod <nimrod@shore.co.il> Date: Wed, 15 Feb 2017 16:32:13 +0200 Subject: [PATCH] - Include bash completion only when the shell is Bash. --- .bashrc | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.bashrc b/.bashrc index e8b4746..b9d6c51 100644 --- a/.bashrc +++ b/.bashrc @@ -28,10 +28,15 @@ if [ -x /usr/bin/dircolors ]; then alias grep='grep --color=auto' fi -if [ -f /etc/bash_completion ]; then - . /etc/bash_completion +if [ -n "$BASH" ] +then + if [ -f /etc/bash_completion ]; then + . /etc/bash_completion + fi + + [ -d $HOME/.bash_completion.d ] && . $HOME/.bash_completion.d/* fi -[ -d $HOME/.bash_completion.d ] && . $HOME/.bash_completion.d/* + if [ -f /usr/local/bin/virtualenvwrapper.sh ] then . /usr/local/bin/virtualenvwrapper.sh -- GitLab