# .bashrc for myers@umich.edu # @(#) $Id: .bashrc,v 1.6 2001/03/20 17:21:49 myers Exp myers $ ###################################################################### # Global definitions & paths: if [ -f /etc/bashrc ]; then . /etc/bashrc fi ############# # Command prompt: case $TERM in xterm*) PROMPT_COMMAND='echo -ne "\033]0;`whoami`@${HOSTNAME}\007"' ;; *) ;; esac PS1="[\h:\W]\$ " ######################## # User specific aliases (those with arguments should be functions) alias emacs="emacs -nw" alias ls="ls -F --color" alias mroe="more" alias rm='rm -i' alias mv='mv -i' alias cp='cp -i' alias cx="chmod +x" alias cw="chmod +w" alias hide="chmod go-rwx" alias unhide="chmod go+r" alias h="history" alias c="clear" alias ll="ls -Flg" alias pd='pushd' alias pop="popd" alias which="type -path" # Shell functions: dirf () { # "full" directory listing ls -ltFg $* | more } dirt () { # directory listing for "today" dt=`date +"%b %d"` ls -ltFg $* | grep "$dt" | more } ffind () { # find a file quickly PAT=$1; shift find . -name "*$PAT*" $* -print } psgrep () { # list specified process ps alxw | grep $1 | grep -v grep } rpmgrep () { # grep the installed rpm list rpm -qa | grep $* } du-s () { du -s * | sort -n } ################# # Do we need these? #export INFOPATH="/usr/info:/usr/local/info:/opt/egcs/info" ################## # Root shells should be limited if [ `whoami` = 'root' ];then TMOUT=3600 PS1="[\W]# " PATH=/usr/local/adm:/usr/local/sbin:/usr/sbin:/sbin:$PATH PATH=`echo $PATH | sed -e "s/\.://"` # Remove 'dot' from path fi