mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-05-08 04:34:00 +02:00
20 lines
638 B
Bash
20 lines
638 B
Bash
function prompt_char {
|
|
git branch >/dev/null 2>/dev/null && echo '±' && return
|
|
echo '○'
|
|
}
|
|
|
|
function virtualenv_info {
|
|
[ $VIRTUAL_ENV ] && echo '('`basename $VIRTUAL_ENV`') '
|
|
}
|
|
|
|
PROMPT='%{$fg[blue]%}✿ %{$reset_color%}[%m]-[${PWD/#$HOME/~}] $(prompt_char) %{$reset_color%}$(git_prompt_info) %{$fg[green]%}➜ %{$reset_color%} '
|
|
|
|
ZSH_THEME_GIT_PROMPT_PREFIX="|%{$fg[green]%}"
|
|
|
|
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}|"
|
|
|
|
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[yellow]%}[✹]%{$reset_color%}"
|
|
|
|
ZSH_THEME_GIT_PROMPT_UNTRACKED="%{$fg[green]%}?%{$reset_color%}"
|
|
|
|
ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg[green]%}(⦿)%{$reset_color%}"
|