Closes #19139: Changed usage of __VENV_NAME__ and added __VENV_PROMPT__.

This commit is contained in:
Vinay Sajip 2013-10-02 11:36:16 +01:00
parent 7c411a4041
commit dff9e2535f
6 changed files with 11 additions and 7 deletions

View file

@ -55,8 +55,8 @@ if test -z "$VIRTUAL_ENV_DISABLE_PROMPT"
# with the original prompt function renamed, we can override with our own.
function fish_prompt
# Prompt override?
if test -n "__VENV_NAME__"
printf "%s%s%s" "__VENV_NAME__" (set_color normal) (_old_fish_prompt)
if test -n "__VENV_PROMPT__"
printf "%s%s%s" "__VENV_PROMPT__" (set_color normal) (_old_fish_prompt)
return
end
# ...Otherwise, prepend env