made skwp theme safe for those without rvm. [fixes #80]
This commit is contained in:
parent
b292a7a33f
commit
408116eea2
@ -9,9 +9,14 @@ function precmd() {
|
|||||||
fi
|
fi
|
||||||
typeset -gi CALCTIME=0
|
typeset -gi CALCTIME=0
|
||||||
}
|
}
|
||||||
|
function safe-rvm-prompt() {
|
||||||
|
if [[ -d ~/.rvm/ ]]; then
|
||||||
|
rvm-prompt
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
PROMPT='%{$fg[blue]%}%~%{$fg_bold[yellow]%}$(git_prompt_info)%{$reset_color%}%{$fg[blue]%}➤ %{$reset_color%}'
|
PROMPT='%{$fg[blue]%}%~%{$fg_bold[yellow]%}$(git_prompt_info)%{$reset_color%}%{$fg[blue]%}➤ %{$reset_color%}'
|
||||||
RPROMPT='%{$fg[blue]%}$(rvm-prompt i v p g) [${ETIME}s] %{$reset_color%}'
|
RPROMPT='%{$fg[blue]%}$(safe-rvm-prompt i v p g) [${ETIME}s] %{$reset_color%}'
|
||||||
|
|
||||||
ZSH_THEME_GIT_PROMPT_PREFIX=" "
|
ZSH_THEME_GIT_PROMPT_PREFIX=" "
|
||||||
ZSH_THEME_GIT_PROMPT_SUFFIX=" "
|
ZSH_THEME_GIT_PROMPT_SUFFIX=" "
|
||||||
|
Loading…
Reference in New Issue
Block a user