MichaelAquilina / zsh-autoswitch-virtualenv

🐍 ZSH plugin to automatically switch python virtualenvs (including pipenv and poetry) as you move between directories
GNU General Public License v3.0
507 stars 80 forks source link

Updating AUTOSWITCH_DEFAULT_PYTHON does not fix the not-found warning #197

Closed nogweii closed 5 months ago

nogweii commented 5 months ago

I have installed Python on my M1 macbook pro via Homebrew. Python is installed as /opt/homebrew/bin/python3. I'm including zsh-autoswitch-virtualenv (cloned as a git submodule) like so:

[ -n "${commands[python3]}" ] && AUTOSWITCH_DEFAULT_PYTHON=python3
source ${DOTSDIR}/zsh/plugins/autoswitch-virtualenv/autoswitch_virtualenv.plugin.zsh
AUTOSWITCH_SILENT='yes'

I believe this is because #176 changed the command that is checked, not including the check for the value of $AUTOSWITCH_DEFAULT_PYTHON.