my xfce4 dotfiles
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
648 B

3 years ago
  1. function prompt_char {
  2. git branch >/dev/null 2>/dev/null && echo '±' && return
  3. hg root >/dev/null 2>/dev/null && echo 'Hg' && return
  4. echo '○'
  5. }
  6. function virtualenv_info {
  7. [ $VIRTUAL_ENV ] && echo '('`basename $VIRTUAL_ENV`') '
  8. }
  9. PROMPT='
  10. %{$fg[magenta]%}%n%{$reset_color%} at %{$fg[yellow]%}%m%{$reset_color%} in %{$fg_bold[green]%}%~%{$reset_color%}$(git_prompt_info)
  11. $(virtualenv_info)$(prompt_char) '
  12. ZSH_THEME_GIT_PROMPT_PREFIX=" on %{$fg[magenta]%}"
  13. ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}"
  14. ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[green]%}!"
  15. ZSH_THEME_GIT_PROMPT_UNTRACKED="%{$fg[green]%}?"
  16. ZSH_THEME_GIT_PROMPT_CLEAN=""