diff options
author | Tom Willemsen | 2012-12-05 00:44:09 +0100 |
---|---|---|
committer | Tom Willemsen | 2012-12-05 00:44:09 +0100 |
commit | 6278e2e634b05027d31220afd328a9f7fe77c6f1 (patch) | |
tree | 3dbec6a3880ca980694def0d737a477b68254691 /.zshrc | |
parent | fa717d86a07d009ab324a40cd8dbf539e61a9da3 (diff) | |
parent | 15adc911da3f5b527c74b6bb67d677898d6a173e (diff) | |
download | dotfiles-6278e2e634b05027d31220afd328a9f7fe77c6f1.tar.gz dotfiles-6278e2e634b05027d31220afd328a9f7fe77c6f1.zip |
Merge remote-tracking branch 'origin/master' into phoenix
Conflicts:
.emacs.d/site-lisp/oni.el
Diffstat (limited to '.zshrc')
-rw-r--r-- | .zshrc | 49 |
1 files changed, 29 insertions, 20 deletions
@@ -1,4 +1,13 @@ # -*- Mode: shell-script; -*- +autoload -Uz add-zsh-hook +autoload -Uz compinit +autoload -U colors +autoload -Uz vcs_info + +# Autoload zsh functions. +fpath=($HOME/.zsh/functions $fpath) +autoload -U $HOME/.zsh/functions/*(:t) + # Setup variables HISTFILE=$ZDOTDIR/histfile HISTSIZE=1000 @@ -25,37 +34,34 @@ alias reboot="systemctl reboot" alias poweroff="systemctl poweroff" setopt notify -# Allow for functions in the prompt -setopt PROMPT_SUBST +setopt PROMPT_SUBST # Allow for functions in the prompt setopt EXTENDED_GLOB zstyle :compinstall filename '$HOME/.zshrc' -autoload -Uz compinit -compinit - -# Initialize colors. -autoload -U colors -colors - -# Autoload zsh functions. -fpath=($HOME/.zsh/functions $fpath) -autoload -U $HOME/.zsh/functions/*(:t) - # Enable auto-execution of functions typeset -ga preexec_functions typeset -ga precmd_functions typeset -ga chpwd_functions -# Append git functions needed for prompt. -preexec_functions+='preexec_update_vars' -precmd_functions+='precmd_update_git_vars' -precmd_functions+='precmd_update_updates' -chpwd_functions+='chpwd_update_git_vars' +add-zsh-hook preexec preexec_update_vars +add-zsh-hook precmd precmd_update_git_vars +add-zsh-hook precmd precmd_update_updates +add-zsh-hook precmd precmd_maybe_festival +add-zsh-hook precmd vcs_info +add-zsh-hook chpwd chpwd_update_git_vars + +zstyle ':vcs_info:*' actionformats '%F{2}(%f%s %r %b%F{2})%f %a + %S' +zstyle ':vcs_info:*' enable bzr git hg svn +zstyle ':vcs_info:*' formats '%F{2}(%f%s %r %b%F{2})%f + %S' +zstyle ':vcs_info:*' nvcsformats ' + %~' +zstyle ':vcs_info:bzr:*' branchformat '%b' # Set the prompt. -PROMPT='$(prompt)' -RPROMPT='$(rprompt)' +PROMPT='%F{1}(%F{2}(%f%m %l%F{2})%f ${vcs_info_msg_0_}%F{1})%f %# ' # Set terminal name to current running application case $TERM in @@ -97,3 +103,6 @@ if [ -z $EMACS ]; then ZSH_HIGHLIGHT_STYLES[double-hyphen-option]='fg=blue' ZSH_HIGHLIGHT_STYLES[single-hyphen-option]='fg=blue' fi + +compinit +colors # Initialize colors. |