diff --git a/themes/agnoster.zsh-theme b/themes/agnoster.zsh-theme index d1a69c560..18496c2bc 100644 --- a/themes/agnoster.zsh-theme +++ b/themes/agnoster.zsh-theme @@ -212,8 +212,8 @@ prompt_virtualenv() { # - am I root # - are there background jobs? prompt_status() { - local symbols - symbols=() + local -a symbols=() + [[ $RETVAL -ne 0 ]] && symbols+="%{%F{red}%}✘" [[ $UID -eq 0 ]] && symbols+="%{%F{yellow}%}⚡" [[ $(jobs -l | wc -l) -gt 0 ]] && symbols+="%{%F{cyan}%}⚙"