mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-05-01 04:30:37 +02:00
Merge 10f2f2fbe2 into 5667161d49
This commit is contained in:
commit
0a83058582
1 changed files with 25 additions and 0 deletions
25
themes/supson.zsh-theme
Normal file
25
themes/supson.zsh-theme
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
function venv {
|
||||
[ $VIRTUAL_ENV ] && echo '['`basename $VIRTUAL_ENV`']'
|
||||
}
|
||||
|
||||
function git_status {
|
||||
ref=$(command git symbolic-ref HEAD 2> /dev/null) || \
|
||||
ref=$(command git rev-parse --short HEAD 2> /dev/null)
|
||||
if [[ -n $ref ]]; then
|
||||
echo "$(parse_git_dirty)"
|
||||
else
|
||||
echo "%{$fg_bold[cyan]%}¯\_(ツ)_/¯"
|
||||
fi
|
||||
}
|
||||
|
||||
function git_branch {
|
||||
echo "$ZSH_THEME_GIT_PROMPT_PREFIX$(command git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/' )$ZSH_THEME_GIT_PROMPT_SUFFIX"
|
||||
}
|
||||
|
||||
PROMPT=' $(git_status) %{$fg_bold[green]%}%3~ » '
|
||||
RPROMPT='%{$fg_bold[magenta]%}$(venv)$(git_branch)%{$fg_bold[green]%}%D{%l:%M:%S}%{$reset_color%}'
|
||||
|
||||
ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[cyan]%}"
|
||||
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}"
|
||||
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg_bold[yellow]%}(╯°□°)╯︵ ┻━┻"
|
||||
ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg_bold[green]%}┬─┬ノ( ゜-゜ノ)"
|
||||
Loading…
Add table
Add a link
Reference in a new issue