Fix errors when calling rbenv

This commit is contained in:
Kujiu 2023-09-06 02:32:26 +02:00
parent 461027a83b
commit e5e2edf52e
Signed by: kujiu
GPG Key ID: ABBB2CAC6855599F
1 changed files with 3 additions and 3 deletions

View File

@ -109,12 +109,12 @@ function fish_prompt --description 'Write out the prompt'
set -f string_env ""
set -f string_venv ""
set -f string_rbenv ""
set -f string_nvm (nvm current)
set -f string_nvm (nvm current 2>/dev/null)
if command -q rbenv
set -f string_rbenv (rbenv local)
set -f string_rbenv (rbenv local 2>/dev/null)
if not test -n string_rbenv
set -f string_rbenv (rbenv global)
set -f string_rbenv (rbenv global 2>/dev/null)
end
if test {"$string_rbenv"} = "system"
set -f string_rbenv ""