comparison .bashrc @ 39:62bfb554ab85

Reorganize zsh files so that bash can work as well.
author Augie Fackler <durin42@gmail.com>
date Mon, 26 Jan 2009 13:21:00 -0600
parents c8d8dcd3f262
children f0f437b22cea
comparison
equal deleted inserted replaced
38:f70862dadf83 39:62bfb554ab85
1 source .zsh/50.vcs_functions.zsh 1 # This is more or less a clone of my .zshrc, with modifications as needed.
2 # The .zshrc is canonical, bash is simply the home-away-from-home when needed.
2 3
4 # one-off alias for a zsh reflex
5 alias ..='cd ..'
6
7 for file in $(ls $HOME/.shell.d/*.{,ba}sh) ; do
8 source $file
9 done
10
11 if [ ! "$SHOWED_SCREEN_MESSAGE" = "true" ]; then
12 if which screen > /dev/null; then
13 detached_screens=`screen -list | grep Detached | sed -e 's/ (Detached)//'`
14 if [ ! -z "$detached_screens" ]; then
15 echo "+---------------------------------------+"
16 echo "| Detached screens are available: |"
17 echo "$detached_screens"
18 echo "+---------------------------------------+"
19 fi
20 fi
21 export SHOWED_SCREEN_MESSAGE="true"
22 fi
23
24 # If available, source private extensions stored in a different repo
25 if [[ -a ~/.private/bashrc ]]; then
26 source ~/.private/bashrc
27 fi
28
29 # I really wish bash had something like .zshenv - maybe I just don't know what it is called?
30 if [[ "x$TZ" == "x" ]] ; then
31 export MACHINE_TZ="xNoTimeZone"
32 local DEFAULT_TZ="America/Detroit"
33 fi
34
35 # Do this right before the timezone stuff
36 if [[ -a ~/.bashrc-machine ]]; then
37 source ~/.bashrc-machine
38 fi
39
40 # do this last so that we can tell if .zshenv-machine set the timezone
41 if [[ "x$TZ" == "x" ]] ; then
42 if [ "$MACHINE_TZ" = "xNoTimeZone" ]; then
43 export TZ="$DEFAULT_TZ"
44 else
45 export TZ="$MACHINE_TZ"
46 fi
47 fi