Merge branch 'master' of unix.club.cc.cmu.edu:~/git/pub/cmccabe-etc
[cmccabe-etc] / .bashrc
1 # .bashrc
2
3 # Source global definitions
4 if [ -f /etc/bashrc ]; then
5         . /etc/bashrc
6 fi
7
8 if [ -f ~/.bashrc-local ]; then
9         . ~/.bashrc-local
10 fi
11
12 xlock2() {
13         ps aux | grep -v grep | grep xscreensaver > /dev/null
14         if [ $? -ne 0 ]; then
15                 echo "starting xscreensaver..."
16                 xscreensaver &
17         fi
18         until xscreensaver-command -lock; do
19                 sleep 1
20         done
21 }
22
23 case $- in
24 *i*)
25         # interactive shell
26         alias ls='ls --color=auto'
27         alias mv='mv -i'
28         alias vi='vim'
29         alias wget='wget --user-agent="Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)"'
30         alias grep='grep --color=tty -d skip'
31         alias mplayer2="mplayer -fs \
32 -vo gl2 \
33 -dr -noslices -xineramascreen 1"
34         alias mplayer="mplayer -fs \
35 -vo gl:yuv=2:noati-hack:rectangle=0:noaspect \
36 -dr -noslices -xineramascreen 1"
37         export PATH="${PATH}:${HOME}/cmccabe-bin"
38         export EDITOR="/usr/bin/vim"
39         export CSCOPE_EDITOR="${EDITOR}"
40         ;;
41 *)
42         # non-interactive shell
43         ;;
44 esac