Virtualenv installation and use of the virtualenvwrapper
Virtualenv can build virtual and independent python runtime environment, making the operating environment and other projects independent of individual projects together. But also can be used to create multiple independent python runtime environment on a single machine, VirtualEnvWrapper provides some convenience package on the command line as the former.
First install virtualenv
pip install virtualenv
After the prompt successful, install virtualenvwrapper
pip install virtualenvwrapper-win
Then create a working directory
- Open the Control Panel - System and Security - System - Advanced System Settings - Environment Variables - System Variables - click New,
- Enter the installation path pthon, double-click virtualenvwrapper.bat in the scripts folder
- Reopen cmd command line window, you can use the
View environment
workon
Creation Environment
mkvirtualenv env-name
It will automatically enter the environment after creating the environment
into the environment
workon env-name
Exit the environment
deactivate
Delete the environment
rmvirtualenv env-name