]> git.rmz.io Git - dotfiles.git/blob - zsh/themes/apple.zsh-theme
cleanup custom folder
[dotfiles.git] / zsh / themes / apple.zsh-theme
1 function toon {
2 echo -n ""
3 }
4
5 get_git_dirty() {
6 git diff --quiet || echo '*'
7 }
8
9 autoload -Uz vcs_info
10 autoload -U colors && colors
11 zstyle ':vcs_info:*' check-for-changes true
12 zstyle ':vcs_info:*' unstagedstr '%F{red}*' # display this when there are unstaged changes
13 zstyle ':vcs_info:*' stagedstr '%F{yellow}+' # display this when there are staged changes
14 zstyle ':vcs_info:*' actionformats \
15 '%F{5}%F{5}[%F{2}%b%F{3}|%F{1}%a%c%u%F{5}]%f '
16 zstyle ':vcs_info:*' formats \
17 '%F{5}%F{5}[%F{2}%b%c%u%F{5}]%f '
18 zstyle ':vcs_info:(sv[nk]|bzr):*' branchformat '%b%F{1}:%F{3}%r'
19 zstyle ':vcs_info:*' enable git cvs svn
20
21 theme_precmd () {
22 vcs_info
23 }
24
25 setopt prompt_subst
26 PROMPT='%{$fg[magenta]%}$(toon)%{$reset_color%} %~/ %{$reset_color%}${vcs_info_msg_0_}%{$reset_color%}'
27
28 autoload -U add-zsh-hook
29 add-zsh-hook precmd theme_precmd