Add better bash completion support

Now it is easy to add new completion scripts: just drop them in the
bash_completion.d directory.

Signed-off-by: Jacob Kiers <kiers@comandi.nl>
This commit is contained in:
Jacob Kiers 2017-12-08 18:33:28 +01:00
parent 12ba7965a4
commit 4b36c35285
3 changed files with 9 additions and 0 deletions

1
.gitignore vendored
View File

@ -1,3 +1,4 @@
*.cache *.cache
sublime/User/Package Control.last-run sublime/User/Package Control.last-run
sublime/User/Package Control.system-ca-bundle sublime/User/Package Control.system-ca-bundle
bash_completion.d

View File

View File

@ -16,3 +16,11 @@ complete -F _tmux t
# Add Gush completion. # Add Gush completion.
[ -f $HOME/.gush/.gush-autocomplete.bash ] && source $HOME/.gush/.gush-autocomplete.bash [ -f $HOME/.gush/.gush-autocomplete.bash ] && source $HOME/.gush/.gush-autocomplete.bash
if [ -d $HOME/dotfiles/bash_completion.d ];
then
for file in `find $HOME/dotfiles/bash_completion.d/ -type f -name '*.sh'`
do
source $file
done
fi