gh-93858: Prevent error when activating venv in nested fish instances (GH-93931)

This commit is contained in:
Thomas B. Brunner 2022-06-27 17:26:02 +02:00 committed by GitHub
parent e5e51556e4
commit 1172172453
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 3 deletions

View File

@ -13,10 +13,13 @@ function deactivate -d "Exit virtual environment and return to normal shell env
end
if test -n "$_OLD_FISH_PROMPT_OVERRIDE"
functions -e fish_prompt
set -e _OLD_FISH_PROMPT_OVERRIDE
functions -c _old_fish_prompt fish_prompt
functions -e _old_fish_prompt
# prevents error when using nested fish instances (Issue #93858)
if functions -q _old_fish_prompt
functions -e fish_prompt
functions -c _old_fish_prompt fish_prompt
functions -e _old_fish_prompt
end
end
set -e VIRTUAL_ENV

View File

@ -0,0 +1 @@
Prevent error when activating venv in nested fish instances.