diff options
Diffstat (limited to 'profile.dot.link')
-rw-r--r-- | profile.dot.link | 27 |
1 files changed, 19 insertions, 8 deletions
diff --git a/profile.dot.link b/profile.dot.link index b1c8d96..40f41d2 100644 --- a/profile.dot.link +++ b/profile.dot.link @@ -98,17 +98,28 @@ export EDITOR="vim" export GIT_PS1_SHOWDIRTYSTATE="" export GIT_PS1_SHOWUNTRACKEDFILES="" -# Load git completion if needed -if [ ! -z "$BASH" ]; then - if ! type __git_ps1 2> /dev/null | head -1 | grep -q function; then - if [ -e "/etc/bash_completion.d/git-prompt" ]; then - . /etc/bash_completion.d/git-prompt - elif [ -e "/etc/bash_completion.d/git" ]; then - . /etc/bash_completion.d/git - fi +# enable programmable completion features (you don't need to enable +# this, if it's already enabled in /etc/bash.bashrc and /etc/profile +# sources /etc/bash.bashrc). +if ! shopt -oq posix; then + if [ -f /usr/share/bash-completion/bash_completion ]; then + . /usr/share/bash-completion/bash_completion + elif [ -f /etc/bash_completion ]; then + . /etc/bash_completion fi fi +# Load git completion if needed +#if [ ! -z "$BASH" ]; then +# if ! type __git_ps1 2> /dev/null | head -1 | grep -q function; then +# if [ -e "/etc/bash_completion.d/git-prompt" ]; then +# . /etc/bash_completion.d/git-prompt +# elif [ -e "/etc/bash_completion.d/git" ]; then +# . /etc/bash_completion.d/git +# fi +# fi +#fi + # Less configuration # See http://seclists.org/fulldisclosure/2014/Nov/74 export LESSSECURE="1" |