mirror of
https://github.com/romkatv/powerlevel10k.git
synced 2024-11-16 09:50:06 +00:00
Improve conditions in rbenv
& pyenv
This commit is contained in:
parent
9f09547ad1
commit
45fe401dc2
1 changed files with 2 additions and 2 deletions
|
@ -1270,7 +1270,7 @@ prompt_rbenv() {
|
|||
elif [ $commands[rbenv] ]; then
|
||||
local rbenv_version_name="$(rbenv version-name)"
|
||||
local rbenv_global="$(rbenv global)"
|
||||
if ! [[ $rbenv_version_name == $rbenv_global && "$POWERLEVEL9K_RBENV_PROMPT_ALWAYS_SHOW" = false ]]; then
|
||||
if [[ "${rbenv_version_name}" != "${rbenv_global}" || "${POWERLEVEL9K_RBENV_PROMPT_ALWAYS_SHOW}" == "true" ]]; then
|
||||
"$1_prompt_segment" "$0" "$2" "red" "$DEFAULT_COLOR" "$rbenv_version_name" 'RUBY_ICON'
|
||||
fi
|
||||
fi
|
||||
|
@ -1635,7 +1635,7 @@ prompt_pyenv() {
|
|||
elif [ $commands[pyenv] ]; then
|
||||
local pyenv_version_name="$(pyenv version-name)"
|
||||
local pyenv_global="$(pyenv version-file-read $(pyenv root)/version)"
|
||||
if ! [[ $pyenv_version_name == $pyenv_global && "$POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW" = false ]]; then
|
||||
if [[ "${pyenv_version_name}" != "${pyenv_global}" || "${POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW}" == "true" ]]; then
|
||||
"$1_prompt_segment" "$0" "$2" "blue" "$DEFAULT_COLOR" "$pyenv_version_name" 'PYTHON_ICON'
|
||||
fi
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue