Awesome
pyenv-autoenv
This is helpful to manage virtual environment automatically. Just enter the project directory via bash and the virtual environment will be set to you.
Instalations
-
Check if dependencies are installed
-
Check out pyenv-autoenv into plugin directory
$ git clone https://github.com/alencarandre/pyenv-autoenv.git $(pyenv root)/plugins/pyenv-autoenv
-
Add
pyenv autoenv init
to your shell to enable auto-activation of virtualenvs.$ echo 'eval "$(pyenv autoenv init)"' >> ~/.bash_profile
Usage
Create .python-virtualenv
file
Inside your project root path, run command bellow:
$ pyenv autoenv your-virtual-environment-name-here
Check version
$ pyenv autoenv version
Upgrade to last version
$ pyenv autoenv upgrade
Limitation and contribution
This plugin was tested only for bash
. If you need to use in other terminal, fell free to test and go ahead to implement or fix something if necessary. Your contribution is thankful.
Licence
The gem is available as open source under the terms of the MIT License.