]> src.twobees.de Git - dotfiles.git/blob - stow/oh-my-zsh/.oh-my-zsh/themes/candy-kingdom.zsh-theme
...
[dotfiles.git] / stow / oh-my-zsh / .oh-my-zsh / themes / candy-kingdom.zsh-theme
1 if ! hg prompt 2>/dev/null; then
2     function hg_prompt_info { }
3 else
4     function hg_prompt_info {
5         hg prompt --angle-brackets "\
6 < on %{$fg[magenta]%}<branch>%{$reset_color%}>\
7 < at %{$fg[yellow]%}<tags|%{$reset_color%}, %{$fg[yellow]%}>%{$reset_color%}>\
8 %{$fg[green]%}<status|modified|unknown><update>%{$reset_color%}<
9 patches: <patches|join( → )|pre_applied(%{$fg[yellow]%})|post_applied(%{$reset_color%})|pre_unapplied(%{$fg_bold[black]%})|post_unapplied(%{$reset_color%})>>" 2>/dev/null
10     }
11 fi
12
13 function box_name {
14   local box="${SHORT_HOST:-$HOST}"
15   [[ -f ~/.box-name ]] && box="$(< ~/.box-name)"
16   echo "${box:gs/%/%%}"
17 }
18
19 PROMPT='
20 %{$fg[magenta]%}%n%{$reset_color%}@%{$fg[yellow]%}$(box_name)%{$reset_color%}:%{$fg_bold[green]%}%~%{$reset_color%}$(hg_prompt_info)$(git_prompt_info)
21 %(?,,%{${fg_bold[white]}%}[%?]%{$reset_color%} )$ '
22
23 ZSH_THEME_GIT_PROMPT_PREFIX=" (%{$fg[magenta]%}branch: "
24 ZSH_THEME_GIT_PROMPT_CLEAN=""
25 ZSH_THEME_GIT_PROMPT_UNTRACKED="%{$fg[red]%}?"
26 ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[orange]%}!"
27 ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%})"
28
29 RPROMPT='%{$fg[red]%}%(?..✘)%{$reset_color%}'
30
31 # Add battery status if the battery plugin is enabled
32 if (( $+functions[battery_pct_prompt] )); then
33     RPROMPT+='$(battery_time_remaining) $(battery_pct_prompt)%{$reset_color%}'
34 fi