rixius.zsh-theme
789 bytes
1# name in folder (github)
2# ± if in github repo, or ≥ if otherwise Time in 24-hour format is on right.
3function collapse_pwd {
4 echo $(pwd | sed -e "s,^$HOME,~,")
5}
6function prompt_char {
7 echo -n "%{$bg[white]%}%{$fg[red]%}"
8 git branch >/dev/null 2>/dev/null && echo "±%{$reset_color%}" && return
9 echo "≥%{$reset_color%}"
10}
11RIXIUS_PRE="%{$bg[white]%}%{$fg[red]%}"
12
13PROMPT='
14%{$RIXIUS_PRE%}%n%{$reset_color%} in %{$fg_bold[green]%}$(collapse_pwd)%{$reset_color%}$(git_prompt_info)
15$(prompt_char) '
16RPROMPT='%{$RIXIUS_PRE%}%T%{$reset_color%}'
17
18ZSH_THEME_GIT_PROMPT_PREFIX=" on %{$fg[magenta]%}"
19ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}"
20ZSH_THEME_GIT_PROMPT_DIRTY=" %{$RIXIUS_PRE%}!%{$reset_color%}"
21ZSH_THEME_GIT_PROMPT_CLEAN=" %{$RIXIUS_PRE%}√%{$reset_color%}"