aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bash/bashrc2
-rw-r--r--sh/profile2
2 files changed, 2 insertions, 2 deletions
diff --git a/bash/bashrc b/bash/bashrc
index f9b0e38d..1fc1df2d 100644
--- a/bash/bashrc
+++ b/bash/bashrc
@@ -67,7 +67,7 @@ shopt -s progcomp 2>/dev/null
# Load any supplementary scripts
if [[ -d $HOME/.bashrc.d ]]; then
for config in "$HOME"/.bashrc.d/*; do
- source "$config"
+ [[ -f $config ]] && source "$config"
done
fi
unset config
diff --git a/sh/profile b/sh/profile
index df1f30d8..bf92b261 100644
--- a/sh/profile
+++ b/sh/profile
@@ -16,7 +16,7 @@ export PATH
# Load all supplementary scripts in ~/.profile.d
if [ -d "$HOME"/.profile.d ]; then
for config in "$HOME"/.profile.d/*; do
- . "$config"
+ [ -f "$config" ] && . "$config"
done
fi
unset config