alanpeabody.zsh-theme 1.0 KB

12345678910111213141516171819202122232425262728
  1. local user='%{$fg[magenta]%}%n@%{$fg[magenta]%}%m%{$reset_color%}'
  2. local pwd='%{$fg[blue]%}%~%{$reset_color%}'
  3. local rvm=''
  4. if which rvm-prompt &> /dev/null; then
  5. rvm='%{$fg[green]%}‹$(rvm-prompt i v g)›%{$reset_color%}'
  6. else
  7. if which rbenv &> /dev/null; then
  8. rvm='%{$fg[green]%}‹$(rbenv version | sed -e "s/ (set.*$//")›%{$reset_color%}'
  9. fi
  10. fi
  11. local return_code='%(?..%{$fg[red]%}%? ↵%{$reset_color%})'
  12. local git_branch='$(git_prompt_status)%{$reset_color%}$(git_prompt_info)%{$reset_color%}'
  13. ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[green]%}"
  14. ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}"
  15. ZSH_THEME_GIT_PROMPT_DIRTY=""
  16. ZSH_THEME_GIT_PROMPT_CLEAN=""
  17. ZSH_THEME_GIT_PROMPT_ADDED="%{$fg[green]%} ✚"
  18. ZSH_THEME_GIT_PROMPT_MODIFIED="%{$fg[blue]%} ✹"
  19. ZSH_THEME_GIT_PROMPT_DELETED="%{$fg[red]%} ✖"
  20. ZSH_THEME_GIT_PROMPT_RENAMED="%{$fg[magenta]%} ➜"
  21. ZSH_THEME_GIT_PROMPT_UNMERGED="%{$fg[yellow]%} ═"
  22. ZSH_THEME_GIT_PROMPT_UNTRACKED="%{$fg[cyan]%} ✭"
  23. PROMPT="${user} ${pwd}$ "
  24. RPROMPT="${return_code} ${git_branch} ${rvm}"