aboutsummaryrefslogtreecommitdiff
path: root/bash/bashrc
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2016-07-30 01:32:30 +1200
committerTom Ryder <tom@sanctum.geek.nz>2016-07-30 02:09:31 +1200
commitd9449c1599ee34a6dd4eac84cf209d9e9017ab69 (patch)
tree8f11f5672ed8ce83fbd52d59c24a19771d69b897 /bash/bashrc
parentCreate separate install-bash-completion target (diff)
downloaddotfiles-d9449c1599ee34a6dd4eac84cf209d9e9017ab69.tar.gz
dotfiles-d9449c1599ee34a6dd4eac84cf209d9e9017ab69.zip
Use terser syntax for .d loop sources
Diffstat (limited to 'bash/bashrc')
-rw-r--r--bash/bashrc26
1 files changed, 10 insertions, 16 deletions
diff --git a/bash/bashrc b/bash/bashrc
index 7338b64c..b551819d 100644
--- a/bash/bashrc
+++ b/bash/bashrc
@@ -106,21 +106,15 @@ if [[ $COMP_WORDBREAKS ]] ; then
fi
# Load any supplementary scripts
-if [[ -d $HOME/.bashrc.d ]] ; then
- for bashrc in "$HOME"/.bashrc.d/*.bash ; do
- if [[ -e $bashrc ]] ; then
- source "$bashrc"
- fi
- done
- unset -v bashrc
-fi
+for bashrc in "$HOME"/.bashrc.d/*.bash ; do
+ [[ -e $bashrc ]] || continue
+ source "$bashrc"
+done
+unset -v bashrc
# Load any completion files
-if [[ -d $HOME/.bash_completion.d ]] ; then
- for bashcmp in "$HOME"/.bash_completion.d/*.bash ; do
- if [[ -e $bashcmp ]] ; then
- source "$bashcmp"
- fi
- done
- unset -v bashcmp
-fi
+for bashcmp in "$HOME"/.bash_completion.d/*.bash ; do
+ [[ -e $bashcmp ]] || continue
+ source "$bashcmp"
+done
+unset -v bashcmp