1 pip install virtualenvwrapper
virtualenvwrapper.sh默认安装在python目录中的bin文件夹下
2 编辑配置文件vi ~/.bashrc
export WORKON_HOME=$HOME/.virtualenvs export VIRTUALENVWRAPPER_PYTHON=/usr/bin/python3 export VIRTUALENVWRAPPER_VIRTUALENV=/usr/local/python3/bin/virtualenv source /usr/local/python3/bin/virtualenvwrapper.sh
3 更新配置文件source ~/.bashrc
4 创建虚拟环境
mkvirtualenv -p python3 site1
https://www.cnblogs.com/apollo1616/p/10222799.html
https://www.jianshu.com/p/7ed2dfa86e90