Use virtualenvwrapper in git bash shells like MINGW64 or Cygwin on Windows 10

Viewed 195

Since I'd been using Linux for almost 10 years, the fact that I had to switch to Windows 10 created several difficulties as for my common workflow using python, pyenv, virtualenvwrapper and bash UNIX shell.

Therefore, I've installed the following shells:

  1. MINGW64 (git shell) via chocolatey package manager in PowerShell: choco install git
  2. Cygwin: https://www.cygwin.com/
  3. Ubuntu (WSL) from the Windows app store

Next, I wanted to set up my favorite virtual environment manager for python called virtualenvwrapper. This resulted to be quite difficult and I ended up installing several versions to find out what eventually works (following commands executed in PowerShell after having installed python3.9.x via pyenv-win in PowerShell):

  1. pip install virtualenvwrapper (pypi.org-page)
  2. pip install virtualenvwrapper-win (pypi.org-page)
  3. Cloning the virtualenvwrapper for PowerShell repo (GitHub-page, installation instructions)

While the 3rd option seems to work in PowerShell, it is a rather reduced version of the real virtualenvwrapper and I'd like to be able to use it in one of my several git/bash/UNIX shells. Yet, when typing in any of the virtualenvwrapper commands in MINGW64 or Cygwin shells, it just returns in both of these shells:

username@... MINGW64 /
$ virtualenvwrapper
bash: virtualenvwrapper: command not found

On the other hand, when I try to install virtualenvwrapper again within these shells via pip, it states that it's already been installed. I assume there's something wrong with the PATHs, but maybe it's even some other issue I haven't thought of.

0 Answers
Related