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

View file

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