From f7da0c5808215bd0501cd61f8f4ed6ca8dde7ffa Mon Sep 17 00:00:00 2001 From: Fotis Gimian Date: Sat, 31 May 2014 12:29:19 +1000 Subject: [PATCH 1/2] Repaired virtualenv activation and deactivation for the fish shell --- bin/pyenv-sh-activate | 2 +- bin/pyenv-sh-deactivate | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/pyenv-sh-activate b/bin/pyenv-sh-activate index 1fca8e6..c390459 100755 --- a/bin/pyenv-sh-activate +++ b/bin/pyenv-sh-activate @@ -41,7 +41,7 @@ fi pyenv-virtualenv-prefix "${versions}" 1>/dev/null -echo "pyenv shell \"${versions}\"" +echo "pyenv shell \"${versions}\";" case "$shell" in fish ) echo ". \"$(pyenv-prefix "${versions}")/bin/activate.fish\"" ;; * ) echo "source \"$(pyenv-prefix "${versions}")/bin/activate\"" ;; diff --git a/bin/pyenv-sh-deactivate b/bin/pyenv-sh-deactivate index a0d2dd9..2889a01 100755 --- a/bin/pyenv-sh-deactivate +++ b/bin/pyenv-sh-deactivate @@ -11,7 +11,7 @@ set -e shell="$(basename "${PYENV_SHELL:-$SHELL}")" case "$shell" in -fish ) echo "functions -q deactivate; and deactivate";; +fish ) echo "functions -q deactivate; and deactivate;";; * ) echo "declare -f deactivate 1>/dev/null 2>&1 && deactivate";; esac echo "pyenv shell --unset" From 21a8745bcf3861bebc9bfa48f06fd362dfc9a842 Mon Sep 17 00:00:00 2001 From: Fotis Gimian Date: Sat, 31 May 2014 15:15:32 +1000 Subject: [PATCH 2/2] Updated tests to correctly pass for fish shell bug fix --- test/activate.bats | 6 +++--- test/deactivate.bats | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/test/activate.bats b/test/activate.bats index 0dd5c42..9f61bc9 100644 --- a/test/activate.bats +++ b/test/activate.bats @@ -19,7 +19,7 @@ setup() { assert_success assert_output <