Permalink
Browse files

.bash: added ~/.bash/*.local overrides

Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
  • Loading branch information...
1 parent db23ded commit 48e1ef86a833bcd18574ba3b22c0aa0cf1d2b988 @trofi committed Oct 20, 2011
Showing with 7 additions and 23 deletions.
  1. +0 −3 .bash/dirs
  2. +5 −20 .bash/rc
  3. +2 −0 .gitignore
View
3 .bash/dirs
@@ -28,7 +28,4 @@ path_prepend () {
}
-export CVSROOT=/srv/cvsroot
-
-
#End ~/.bash/dirs
View
25 .bash/rc
@@ -1,26 +1,11 @@
# Begin ~/.bash/rc
# Personal aliases and functions.
-if [ -f "$HOME/.bash/dirs" ] ; then
- source $HOME/.bash/dirs
-fi
-
-if [ -f "$HOME/.bash/alias" ] ; then
- source $HOME/.bash/alias
-fi
-
-if [ -f "$HOME/.bash/colors" ] ; then
- source $HOME/.bash/colors
-fi
-
-if [ -f "$HOME/.bash/vars" ] ; then
- source $HOME/.bash/vars
-fi
-
-if [ -f "$HOME/.bash/funs" ] ; then
- source $HOME/.bash/funs
-fi
-
+for cfg in dirs alias colors vars funs
+do
+ [[ -f $HOME/.bash/${cfg} ]] && source "$HOME/.bash/${cfg}"
+ [[ -f $HOME/.bash/${cfg}.local ]] && source "$HOME/.bash/${cfg}.local"
+done
#if [ -f "/etc/bashrc" ] ; then
# source /etc/bashrc
View
2 .gitignore
@@ -0,0 +1,2 @@
+# per-machive overrides
+.bash/*.local

0 comments on commit 48e1ef8

Please sign in to comment.