Dotfiles/.zsh/lib/promt.zsh
Nis Wechselberg f158a62226 Customized colors on prompt
Moved Completion Cache from .oh-my-zsh to .zsh
2014-04-07 02:44:41 +02:00

26 lines
903 B
Bash

# autoload -U add-zsh-hook
autoload -Uz vcs_info
# # enable VCS systems you use
zstyle ':vcs_info:*' enable git svn
zstyle ':vcs_info:*:prompt:*' check-for-changes true
setopt prompt_subst
autoload -U promptinit
promptinit
# Look at http://zsh.sourceforge.net/Doc/Release/User-Contributions.html#Version-Control-Information
# for mor options
zstyle ':vcs_info:*' check-for-changes true
zstyle ':vcs_info:*' unstagedstr '*' # display this when there are unstaged changes
zstyle ':vcs_info:*' stagedstr '+' # display this when there are staged changes
zstyle ':vcs_info:*' actionformats '[%b%|%a%c%u%]%f'
zstyle ':vcs_info:*' formats ':%b%c%u%f'
zstyle ':vcs_info:(sv[nk]|bzr):*' branchformat '%b%F{1}:%F{3}%r'
precmd () { vcs_info }
PROMPT='[%{$fg[blue]%}%n@%m%{$reset_color%} %~%{$fg[green]%}${vcs_info_msg_0_}%{$reset_color%}] %{$reset_color%}'
# RPROMPT='%{$fg[blue]%}%n@%m%{$reset_color%}'