From 74f2dd7daeea5d1c4f689ca1504db47bd887a862 Mon Sep 17 00:00:00 2001
From: "Kenneth Benzie (Benie)" <benie@infektor.net>
Date: Tue, 22 Mar 2022 13:26:32 +0000
Subject: [PATCH] Fix `autoenv add=py` .enter when run in subdirectory

---
 autoenv/autoenv.zsh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/autoenv/autoenv.zsh b/autoenv/autoenv.zsh
index 307db98..72fe0aa 100644
--- a/autoenv/autoenv.zsh
+++ b/autoenv/autoenv.zsh
@@ -98,7 +98,7 @@ commands:
       fi
       _autoenv_exit $PWD
       virtualenv .local
-      echo 'source .local/bin/activate' >> .enter
+      echo 'source ${0:a:h}/.local/bin/activate' >> .enter
       echo 'deactivate' >> .exit
       _autoenv_authorized $PWD/.enter yes
       _autoenv_authorized $PWD/.exit yes