dotfiles

config files for my linux setup
git clone git://edryd.org/dotfiles
Log | Files | Refs | README

zshrc (1234B)


      1 # basic {{{1
      2 setopt autocd extendedglob nomatch notify
      3 unsetopt beep
      4 bindkey -e
      5 
      6 # history settings
      7 HISTFILE=~/.histfile
      8 HISTSIZE=1000
      9 SAVEHIST=1000
     10 
     11 # completion stuf
     12 zstyle ':completion:*' completer _complete _ignored
     13 zstyle :compinstall filename '/home/ed/.zshrc'
     14 autoload -Uz compinit
     15 compinit
     16 
     17 # load files
     18 source ~/bin/ED.sh
     19 source ~/bin/checkium.sh
     20 source ~/bin/colors.sh
     21 source ~/bin/git-prompt.sh
     22 source ~/bin/z.sh
     23 
     24 # prompt statement {{{1
     25 # change color of branch name
     26 git_color() {
     27     if [ -d .git ] || git rev-parse --git-dir > /dev/null 2>&1; then
     28         local color="${Cyan}"
     29 
     30         # modified
     31         git diff --no-ext-diff --quiet --exit-code || color="${Red}"
     32 
     33         # staged
     34         if git rev-parse --quiet --verify HEAD >/dev/null; then
     35             git diff-index --cached --quiet HEAD -- || color="${IRed}"
     36         fi
     37 
     38         # stashed
     39         git rev-parse --verify refs/stash >/dev/null 2>&1 && color="${Yellow}"
     40 
     41         echo "$color"
     42     fi
     43 }
     44 
     45 # PS1="%{$Blue%}%M \
     46 # $(checkium_color)$(checkium_random_face) \
     47 # $(git_color)$(__git_ps1 "%s ")%{$Yellow%}\
     48 # $([ $(jobs | wc -l) -gt 0 ] && echo "%j ")%{$White%}\
     49 # \$%{$Color_Off%} "
     50 
     51 PS1="%{$White%}\$%{$Color_Off%} "
     52 
     53 PS2="%{$White%}\$%{$Color_Off%} "