Created
November 22, 2012 12:52
-
-
Save gusano/4131047 to your computer and use it in GitHub Desktop.
.zshrc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Don't kill jobs when logout --------------------------------------- | |
setopt nohup | |
# prompt ------------------------------------------------------------ | |
PS1=$'%{\e[1;36m%}(%{\e[31m%}%30<..<%~%{\e[36m%}) %{\e[36m%}%#%b %{\e[0m%}' | |
if [ "`id -u`" -eq 0 ]; then | |
export RPS1=$'%{\e[37m%}%{\e[1;30m%}%{\e[7m%} %M %{\e[0m%}' | |
else | |
export RPS1=$'%{\e[37m%}%{\e[1;30m%} %M %{\e[0m%}' | |
fi | |
# completion -------------------------------------------------------- | |
zstyle ':completion:*' menu select=1 # completion menu | |
unsetopt list_ambiguous # prompt after 1st tab | |
setopt glob_dots # completion for dot files | |
# aliases ----------------------------------------------------------- | |
# ls stuff | |
alias ls='ls --classify --color=auto --human-readable --time-style=locale' | |
alias l='ls' | |
alias ll='ls -l' | |
alias la='ls -a' | |
alias lla='ls -la' | |
alias lsa='ls -ld .*' | |
alias lsd='ls -ld *(-/DN)' | |
# handy | |
alias df='df --human-readable' | |
alias du='du --human-readable' | |
alias grep='grep --color' | |
# various ----------------------------------------------------------- | |
bindkey -e # emacs key bindings | |
unsetopt beep # no beep please | |
unsetopt ignore_eof # Ctrl+D acts like a 'logout' | |
setopt print_exit_value # print exit code if different from '0' | |
unsetopt rm_star_silent # confirmation asked for 'rm *' | |
# history ----------------------------------------------------------- | |
export HISTORY=1600 | |
export SAVEHIST=1600 | |
export HISTFILE=$HOME/.history | |
setopt hist_verify # prompt before execution | |
# colorful manpages ------------------------------------------------- | |
export LESS_TERMCAP_mb=$'\E[01;31m' | |
export LESS_TERMCAP_md=$'\E[01;37m' | |
export LESS_TERMCAP_me=$'\E[0m' | |
export LESS_TERMCAP_se=$'\E[0m' | |
export LESS_TERMCAP_so=$'\E[01;44;33m' | |
export LESS_TERMCAP_ue=$'\E[0m' | |
export LESS_TERMCAP_us=$'\E[01;32m' | |
# editor ----------------------------------------------------------- | |
export EDITOR="nano" | |
# key bindings ----------------------------------------------------- | |
bindkey ';5D' emacs-backward-word # CTRL+LEFT jumps word backward | |
bindkey ';5C' emacs-forward-word # CTRL+RIGHT jumps word forward | |
# ------------------------------------------------------------------ | |
# The following lines were added by compinstall | |
zstyle :compinstall filename '/home/vagrant/.zshrc' | |
autoload -Uz compinit | |
compinit | |
# End of lines added by compinstall |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment