Permalink
Browse files

Start using bashrc_dispatch.

  • Loading branch information...
1 parent cc46a63 commit c10a68a9f9fefb180e604b671916846ba79affd6 @arnsholt committed Feb 19, 2013
Showing with 44 additions and 35 deletions.
  1. +7 −35 dot.bashrc → dot.bashrc_all
  2. +30 −0 dot.bashrc_interactive
  3. +7 −0 install.sh
@@ -1,32 +1,4 @@
-# .bashrc
-
-# Source global definitions
-if [ -f /etc/bashrc ]; then
- . /etc/bashrc
-fi
-
-if [ -f /etc/bash_completion ]; then
- . /etc/bash_completion
-elif [ -f ~/.bash_completion ]; then
- . ~/.bash_completion
-fi
-
-if [ -d ~/.bash_completion.d ]; then
- for f in ~/.bash_completion.d/*; do
- . $f
- done
-fi
-
-LOGONROOT=~/logon
-if [ -f ${LOGONROOT}/dot.bashrc ]; then
- . ${LOGONROOT}/dot.bashrc
-fi
-
-test -f ~/.dircolors && eval `dircolors ~/.dircolors`
-
-test -e ~/perl5 && source ~/perl5/perlbrew/etc/bashrc
-
-stty stop undef
+# Sourced for -all- shells. Mostly setting up paths.
export MANPATH=/usr/share/man:~/sw/share/man
export PKG_CONFIG_PATH=~/sw/lib/pkgconfig
@@ -42,10 +14,10 @@ export XLEPATH=~/sw/app/xle
export PATH=${XLEPATH}/bin:$PATH
export LD_LIBRARY_PATH=${XLEPATH}/lib:$LD_LIBRARY_PATH
-alias alisp="rlwrap alisp"
-alias vi=vim
+LOGONROOT=~/logon
+if [ -f ${LOGONROOT}/dot.bashrc ]; then
+ . ${LOGONROOT}/dot.bashrc
+fi
+
+test -e ~/perl5 && source ~/perl5/perlbrew/etc/bashrc
-export SQLHOST=mysql.ifi SQLUSER=arnskj SQLDB=arnskj
-export PS1="[\u@\h \w]\$ "
-export EDITOR=vim
-export BROWSER=opera
View
@@ -0,0 +1,30 @@
+# .bashrc
+
+# Source global definitions
+if [ -f /etc/bashrc ]; then
+ . /etc/bashrc
+fi
+
+if [ -f /etc/bash_completion ]; then
+ . /etc/bash_completion
+elif [ -f ~/.bash_completion ]; then
+ . ~/.bash_completion
+fi
+
+if [ -d ~/.bash_completion.d ]; then
+ for f in ~/.bash_completion.d/*; do
+ . $f
+ done
+fi
+
+test -f ~/.dircolors && eval `dircolors ~/.dircolors`
+
+stty stop undef
+
+alias alisp="rlwrap alisp"
+alias vi=vim
+
+export SQLHOST=mysql.ifi SQLUSER=arnskj SQLDB=arnskj
+export PS1="[\u@\h \w]\$ "
+export EDITOR=vim
+export BROWSER=opera
View
@@ -27,3 +27,10 @@ for file in dot.*; do
install "$file" "$HOME" "$shortname"
done
+
+# Special handling for .bash*
+
+for f in rc _profile _login; do
+ file=".bash$f"
+ install "bashrc_dispatch/bashrc_dispatch" "$HOME" "$file"
+done

0 comments on commit c10a68a

Please sign in to comment.