mirror of
https://github.com/pyenv/pyenv-virtualenv.git
synced 2026-09-13 00:36:19 -04:00
fix fish prompt
This commit is contained in:
parent
2b2b87a25a
commit
9d0e422d3f
|
|
@ -245,7 +245,14 @@ if [ -z "${PYENV_VIRTUALENV_DISABLE_PROMPT}" ]; then
|
|||
case "${shell}" in
|
||||
fish )
|
||||
if [ -z "${QUIET}" ]; then
|
||||
echo "pyenv-virtualenv: prompt changing not working for fish." 1>&2
|
||||
cat <<EOS
|
||||
functions -e _pyenv_old_prompt
|
||||
functions -c fish_prompt _pyenv_old_prompt
|
||||
function fish_prompt
|
||||
echo -n "(${venv}) "
|
||||
_pyenv_old_prompt
|
||||
end
|
||||
EOS
|
||||
fi
|
||||
;;
|
||||
* )
|
||||
|
|
|
|||
|
|
@ -187,7 +187,13 @@ esac
|
|||
|
||||
case "${shell}" in
|
||||
fish )
|
||||
:
|
||||
cat <<EOS
|
||||
if functions -q _pyenv_old_prompt
|
||||
functions -e fish_prompt
|
||||
functions -c _pyenv_old_prompt fish_prompt
|
||||
functions -e _pyenv_old_prompt
|
||||
end
|
||||
EOS
|
||||
;;
|
||||
* )
|
||||
cat <<EOS
|
||||
|
|
|
|||
Loading…
Reference in a new issue