# Charlton's generic .zshrc file (for any user including root) # Written for zsh version 4.0.X # Paths were designed for Gentoo Linux # set path path=(. /usr/local/bin /usr/bin /bin /usr/X11R6/bin \ /usr/games/bin /usr/games /usr/local/games \ /usr/include /usr/include/sys /usr/include/linux /usr/etc \ /sbin /usr/sbin /usr/local/sbin \ ~/ ~/bin /home/charlton/bin ~/.bin /los/bin $path) # set manpath manpath=(. /usr/local/man /usr/local/share/man /usr/man /usr/share/man \ /usr/X11R6/man /usr/lib/perl5/man $manpath) # remove duplicate entries from path and manpath typeset -U path manpath # Set environment variables export REPLYTO='charlton@dynet.com' export EDITOR='/usr/bin/vim' export VISUAL='/usr/bin/vim' #export PGLIB='/usr/lib/pgsql' #export PGDATA='/home/charlton/music/db' # Got this from the list at: # http://www.irchelp.org/irchelp/networks/servers/efnet.html #export IRCSERVER='irc.vorbis.com' export IRCSERVER='irc.freenode.net' # irc.prison.net irc.lightning.net irc.texas.net irc.lagged.org irc.idle.net irc.colorado.edu irc.core.com irc.lsl.com irc.phoenix.net irc-2.texas.net irc.cerf.net irc2.home.com irc.stanford.edu irc.best.net irc.concentric.net irc-w.frontiernet.net irc.emory.edu irc.mindspring.com irc.mcs.net irc.freei.net irc.mpl.net irc.nethead.com" export NNTPSERVER='news-server.austin.rr.com' export NNTP='news-server.austin.rr.com' # Set auto-completion autoload -U compinit compinit -C # General Options: # Do not report the status of background and suspended jobs before exiting # a shell with job control; a second attempt to exit the shell will succeed. setopt no_check_jobs # Do not kill jobs upon exiting the shell setopt no_hup # Do not run background jobs at any lower priority unless specified by me. setopt no_bg_nice # Do not beep at me when I'm trying to auto-complete setopt nobeep # Resolve symbolic links to their true values when changing directory. setopt chase_links # If this hasn't already been done: umask 022 # Suppress "You have new mail" messages at every other prompt. MAILCHECK=0 setopt no_mail_warning # Set $COLOR variables local C00=$'%{\e[0m%}' # 00 Normal local C01=$'%{\e[1;31m%}' # 01 Red local C02=$'%{\e[1;32m%}' # 02 Green local C03=$'%{\e[1;33m%}' # 03 Yellow local C04=$'%{\e[1;34m%}' # 04 Blue local C05=$'%{\e[1;35m%}' # 05 Pink / Violet / Light Purple local C06=$'%{\e[1;36m%}' # 06 Cyan local C07=$'%{\e[1;37m%}' # 07 Grey (White?) local C08=$'%{\e[1;38m%}' # 08 Grey (White?) local C09=$'%{\e[1;39m%}' # 09 Grey (White?) local C10=$'%{\e[1;30m%}' # 10 Dark Grey local C11=$'%{\e[2;31m%}' # 11 Dark Red local C12=$'%{\e[2;32m%}' # 12 Dark Green local C13=$'%{\e[2;33m%}' # 13 Dark Yellow (Brown) local C14=$'%{\e[2;34m%}' # 14 Dark Blue local C15=$'%{\e[2;35m%}' # 15 Dark Purple local C16=$'%{\e[2;36m%}' # 16 Dark Cyan local C17=$'%{\e[2;37m%}' # 17 Lighter Grey (Dark White) local CBL=$'%{\e[5;38m%}' # BL Blink # Different machines; different hostname colors... case $HOST in bach*) local CHM=$C01 ;; mozart*) local CHM=$C04 ;; bartok*) local CHM=$C13 ;; holst*) local CHM=$C02 ;; charlton*) local CHM=$C05 ;; *) local CHM=$C00 ;; esac # Set prompt if (( EUID == 0 )); then # For root perhaps add more to the path # path=($path /sbin /usr/sbin /usr/local/sbin) # Playing around with color prompts... # My original prompt # PS1=$'%m *ROOT* %d (%h)>' # Not blinking # PS1=$'%{\e[1;31m%}%m%{\e[0m%} *ROOT* %{\e[1;36m%}%d%{\e[0m%} %{\e[2;37m%}(%{\e[0m%}%{\e[1;33m%}%h%{\e[0m%}%{\e[2;37m%})%{\e[0m%}>' # Blinking *ROOT* (I know it's annoying but it's to encourage not being root) # PS1=$'%{\e[1;31m%}%m%{\e[0m%} %{\e[5;38m%}*ROOT*%{\e[0m%} %{\e[1;36m%}%d%{\e[0m%} %{\e[2;37m%}[%{\e[0m%}%{\e[1;33m%}%h%{\e[0m%}%{\e[2;37m%}]%{\e[0m%}>' PS1=$CHM%m$C00$' '$CBL$'*ROOT*'$C00$' '$C06%d$C00$' '$C17$'['$C03%h$C00$C17$']'$C00$'>' else # PS1=$'%m %d [%h]>' # PS1=$'%{\e[1;31m%}%m%{\e[0m%} %{\e[1;36m%}%d%{\e[0m%} %{\e[2;37m%}[%{\e[0m%}%{\e[1;33m%}%h%{\e[0m%}%{\e[2;37m%}]%{\e[0m%}>' PS1=$CHM%m$C00$' '$C06%d$C00$' '$C17$'['$C03%h$C00$C17$']'$C00$'>' fi # or use neat prompt themes included with zsh autoload -U promptinit promptinit # Currently available prompt themes (prompt -l): # adam1 adam2 bart bigfade clint elite2 elite # fade fire off oliver redhat suse walters zefram #prompt elite2 # live history buffer HISTSIZE=9999 # Make cd push the old directory onto the directory stack. DIRSTACKSIZE=16 setopt auto_pushd #setopt pushd_silent setopt pushd_ignoredups # exchange meaning of + and - setopt pushd_minus alias cdb='pushd -1' alias cdf='pushd +0' # Set colors for GNU ls ; set this to right file eval `dircolors /etc/DIR_COLORS` alias ls='ls --color=auto' # Set up aliases # Basic alias l='ls -al' alias ll='ls -l' alias la='ls -a' alias df='df -k' alias mv='mv -i' alias psx='ps auxww' alias p='ps -fu $USER' alias h='history -40' alias cls='clear' # App stuff alias xsnow='xsnow -notrees -nosanta' alias lookup='dict' alias tn='telnet' alias bc='pari -fq' alias show='echo "";free;echo "";cal `date|cut -c25-28`;df;echo "";uname -a;uptime;date;echo ""' alias bitchx='BitchX' alias pari='gp' alias vi='/usr/bin/vim' alias vim='/usr/X11/bin/gvim' #alias who='w' #alias nets='ps ax | grep nets' #alias gal='ps ax | grep galeon' alias vc='vorbiscomment' # LOS stuff alias sm='summarize' alias sch='summarize sch' # These fucking apps keep crashing... alias lopster='while ((1)) ; do lopster ; sleep 10 ; done' alias gkrellm='while ((1)) ; do gkrellm2 -g +500+500 ; sleep 15 ; done'