Add .zshrc.
authorShingo W. Kagami
Thu, 31 Dec 2009 21:39:18 +0900
changeset 05771d060b6cb
child 1 a67b577d427b
Add .zshrc.
.zshrc
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/.zshrc	Thu Dec 31 21:39:18 2009 +0900
     1.3 @@ -0,0 +1,61 @@
     1.4 +# Lines configured by zsh-newuser-install
     1.5 +
     1.6 +HISTFILE=~/.histfile
     1.7 +HISTSIZE=1000000
     1.8 +SAVEHIST=1000000
     1.9 +setopt appendhistory
    1.10 +setopt share_history
    1.11 +setopt hist_ignore_dups
    1.12 +setopt auto_pushd
    1.13 +setopt magic_equal_subst
    1.14 +bindkey -e
    1.15 +# End of lines configured by zsh-newuser-install
    1.16 +# The following lines were added by compinstall
    1.17 +# zstyle :compinstall filename '/home/swk/.zshrc'
    1.18 +
    1.19 +fpath=($fpath /usr/share/zsh/functions/Zle)
    1.20 +autoload -U compinit
    1.21 +compinit -u
    1.22 +# End of lines added by compinstall
    1.23 +
    1.24 +autoload history-search-end
    1.25 +zle -N history-beginning-search-backward-end history-search-end
    1.26 +zle -N history-beginning-search-forward-end history-search-end
    1.27 +bindkey '^P' history-beginning-search-backward-end
    1.28 +bindkey '^N' history-beginning-search-forward-end
    1.29 +
    1.30 +export CVS_RSH=ssh
    1.31 +export RSYNC_RSH=ssh
    1.32 +export EDITOR=vi
    1.33 +export PAGER=less
    1.34 +export JLESSCHARSET=ja
    1.35 +export LS_COLORS="di=31:ex=34:ln=46:pi=0:so=0:cd=0:bd=0"
    1.36 +
    1.37 +alias ls="ls --color=tty"
    1.38 +alias l="ls -l"
    1.39 +alias lynx="lynx -nopause"
    1.40 +
    1.41 +case "$OSTYPE" in
    1.42 +    freebsd*)
    1.43 +	alias ls="gnuls --color=tty"
    1.44 +	alias emacs=emcws
    1.45 +	alias less=jless
    1.46 +	;;
    1.47 +    cygwin)
    1.48 +        alias start=cygstart
    1.49 +	alias ls="ls --color=tty --show-control-chars"
    1.50 +	;;
    1.51 +esac
    1.52 +
    1.53 +PROMPT=$'%{\e[35m%}%m%#%{\e[m%} '
    1.54 +precmd() { RPROMPT="[$PWD]" }
    1.55 +
    1.56 +dirbase() { basename `pwd` }
    1.57 +chpwd() { [ "x$TERM" = "xscreen" ] && echo -n "\ek`hostname | cut -b 1-3`:`dirbase`\e\\" }
    1.58 +
    1.59 +chpwd
    1.60 +
    1.61 +if [ -e ${HOME}/.zshrc.local ]; then
    1.62 +    source ${HOME}/.zshrc.local
    1.63 +fi
    1.64 +