From 9f3afd0cfb7e24e4693761761a03fc6a0e122df1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jovier=20A=2E=20Jim=C3=A9nez?= Date: Mon, 19 Feb 2024 21:18:56 -0800 Subject: [PATCH] allow users to configure prompt add-on --- bin/pyenv-sh-activate | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/bin/pyenv-sh-activate b/bin/pyenv-sh-activate index d6b0d35..70072b9 100755 --- a/bin/pyenv-sh-activate +++ b/bin/pyenv-sh-activate @@ -262,9 +262,14 @@ EOS fi ;; * ) + if [ -z "${PYENV_VIRTUALENV_PROMPT}" ]; then + PYENV_VIRTUALENV_PROMPT="(${venv})" + else + PYENV_VIRTUALENV_PROMPT="${PYENV_VIRTUALENV_PROMPT/\{venv\}/${venv}}" + fi cat <