-
Notifications
You must be signed in to change notification settings - Fork 52
~/.bash_completion is sourced twice #171
Description
By default the current implementation loads user completion file twice: first by /usr/share/bash-completion/bash_completion in bash-completion package which is called by /etc/bash.bashrc via /etc/profile.d/bash_completion.sh and then directly by /etc/bash.bashrc itself.
I think /etc/bash.bashrc is not a right place to source user ~/.bash_completion at all. Especially when it gets sourced by bash-completion package already since 2001 but added to /etc/bash.bashrc in 2013.
I can see only one use case for that when user has its own completions created but doesn't install bash-completion package which probably happens quite unlikely. But even if such situation happens I'd rather let user itself source it using $HOME/.bash.expert that is made specially for cases when user is looking for a its own customization.