mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2024-11-19 21:41:07 +01:00
e8504ac49a
that only change the foreground color. %F works at least since Zsh 4.3.
14 lines
418 B
Bash
14 lines
418 B
Bash
if [ $UID -eq 0 ]; then NCOLOR="red"; else NCOLOR="green"; fi
|
|
local return_code="%(?..%F{red}%? ↵%f)"
|
|
|
|
PROMPT='%F{$NCOLOR}%n%f@%F{cyan}%m\
|
|
%f:%F{magenta}%~\
|
|
$(git_prompt_info) \
|
|
%F{red}%(!.#.»)%f '
|
|
PROMPT2='%F{red}\ %f'
|
|
RPS1='${return_code}'
|
|
|
|
ZSH_THEME_GIT_PROMPT_PREFIX="%F{yellow}("
|
|
ZSH_THEME_GIT_PROMPT_CLEAN="%F{green}○%f"
|
|
ZSH_THEME_GIT_PROMPT_DIRTY="%F{red}⚡%f"
|
|
ZSH_THEME_GIT_PROMPT_SUFFIX="%F{yellow})%f"
|