mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2024-11-15 01:48:34 -07:00
fix(ys): fix $VIRTUAL_ENV
check if nounset
is enabled (#9915)
This commit is contained in:
parent
59c40eee8e
commit
303ae79712
@ -49,7 +49,7 @@ local venv_info='$(virtenv_prompt)'
|
||||
YS_THEME_VIRTUALENV_PROMPT_PREFIX=" %{$fg[green]%}"
|
||||
YS_THEME_VIRTUALENV_PROMPT_SUFFIX=" %{$reset_color%}%"
|
||||
virtenv_prompt() {
|
||||
[[ -n ${VIRTUAL_ENV} ]] || return
|
||||
[[ -n "${VIRTUAL_ENV:-}" ]] || return
|
||||
echo "${YS_THEME_VIRTUALENV_PROMPT_PREFIX}${VIRTUAL_ENV:t}${YS_THEME_VIRTUALENV_PROMPT_SUFFIX}"
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user