zshrc 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. # Lines configured by zsh-newuser-install
  2. HISTFILE=~/.histfile
  3. HISTSIZE=1000
  4. SAVEHIST=1000
  5. setopt incappendhistory nomatch correct
  6. unsetopt beep
  7. bindkey -v
  8. zstyle :compinstall filename '/home/drew/.zshrc'
  9. autoload -Uz compinit
  10. compinit
  11. autoload -U colors && colors
  12. # Have to reset color to cyan after the bold tags for some reason.
  13. PROMPT="%{$fg[cyan]%}[%n@%M %B%1~%b%{$fg[cyan]%}]%# %{$reset_color%}"
  14. alias ll='ls -alF'
  15. alias la='ls -A'
  16. alias l='ls -CF'
  17. alias ls='ls --color=auto'
  18. eval "$(hub alias -s)"
  19. # Allow ctrl+S in vim to save files, ie pass
  20. # the command to vim when vim is open.
  21. vim() {
  22. local STTYOPTS="$(stty --save)"
  23. stty stop '' -ixoff
  24. command vim --servername vim "$@"
  25. stty "$STTYOPTS"
  26. }
  27. export EDITOR="vim"
  28. # Set Home, End, Del, PgUp, PgDown keys to actually do something.
  29. bindkey '^[OH' beginning-of-line
  30. bindkey '^[OF' end-of-line
  31. bindkey '^[[3~' delete-char
  32. bindkey '^[[5~' beginning-of-buffer-or-history
  33. bindkey '^[[6~' end-of-buffer-or-history
  34. if [ -x /usr/bin/ssh-agent -a -z "$SSH_AUTH_SOCK" ]; then
  35. eval "$(keychain --eval -Q -q --agents ssh `find $HOME/.ssh/* ! -name '*.pub' ! -name 'config' ! -name 'known_hosts'`)"
  36. fi
  37. export PATH="$PATH:$HOME/.rvm/bin"
  38. [[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"
  39. source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh