aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bash/bash_profile6
-rw-r--r--bash/bashrc2
-rw-r--r--sh/profile3
3 files changed, 7 insertions, 4 deletions
diff --git a/bash/bash_profile b/bash/bash_profile
new file mode 100644
index 00000000..aa87667d
--- /dev/null
+++ b/bash/bash_profile
@@ -0,0 +1,6 @@
+# Source Bourne shell profile if it exists
+[[ -r "$HOME/.profile" ]] && source $HOME/.profile
+
+# Source interactive Bash config if it exists
+[[ -r "$HOME/.bashrc" ]] && source $HOME/.bashrc
+
diff --git a/bash/bashrc b/bash/bashrc
index cdfcaffe..4891b61a 100644
--- a/bash/bashrc
+++ b/bash/bashrc
@@ -58,7 +58,7 @@ setterm -bfreq 0 &>/dev/null
stty -ixon &>/dev/null
# Use completion, if available
-[[ -e /etc/bash_completion ]] && source /etc/bash_completion
+[[ -r /etc/bash_completion ]] && source /etc/bash_completion
# I always want a unified diff
alias diff='diff -u'
diff --git a/sh/profile b/sh/profile
index a81d12e0..d5a2fec8 100644
--- a/sh/profile
+++ b/sh/profile
@@ -18,6 +18,3 @@ then
done
fi
-# If running Bash, try to run .bashrc
-[ -n "$BASH" -a -e "$HOME/.bashrc" ] && . $HOME/.bashrc
-