Skip to content

Instantly share code, notes, and snippets.

@ludamillion
Last active January 9, 2017 16:36
Show Gist options
  • Save ludamillion/d9448a2f8cc3ea83f5d5215606feed8d to your computer and use it in GitHub Desktop.
Save ludamillion/d9448a2f8cc3ea83f5d5215606feed8d to your computer and use it in GitHub Desktop.
ZSH_THEME_GIT_PROMPT_PREFIX="%{$reset_color%}%{$fg[white]%}["
ZSH_THEME_GIT_PROMPT_SUFFIX=""
ZSH_THEME_GIT_PROMPT_DIRTY=" %{$fg[red]%}●%{$fg[white]%}]%{$reset_color%} "
ZSH_THEME_GIT_PROMPT_CLEAN="]%{$reset_color%} "
ZSH_THEME_SVN_PROMPT_PREFIX=$ZSH_THEME_GIT_PROMPT_PREFIX
ZSH_THEME_SVN_PROMPT_SUFFIX=$ZSH_THEME_GIT_PROMPT_SUFFIX
ZSH_THEME_SVN_PROMPT_DIRTY=$ZSH_THEME_GIT_PROMPT_DIRTY
ZSH_THEME_SVN_PROMPT_CLEAN=$ZSH_THEME_GIT_PROMPT_CLEAN
ZSH_THEME_HG_PROMPT_PREFIX=$ZSH_THEME_GIT_PROMPT_PREFIX
ZSH_THEME_HG_PROMPT_SUFFIX=$ZSH_THEME_GIT_PROMPT_SUFFIX
ZSH_THEME_HG_PROMPT_DIRTY=$ZSH_THEME_GIT_PROMPT_DIRTY
ZSH_THEME_HG_PROMPT_CLEAN=$ZSH_THEME_GIT_PROMPT_CLEAN
vcs_status() {
if [[ $(whence in_svn) != "" ]] && in_svn; then
svn_prompt_info
elif [[ $(whence in_hg) != "" ]] && in_hg; then
hg_prompt_info
else
git_prompt_info
fi
}
PROMPT='%{$fg_bold[green]%}%3/%{$reset_color%} $(vcs_status)»%b '
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment