雀栖梧枝,希瑟姐妹,人民日报电子版
安装
$ pip install pipenv
安装虚拟环境
pipenv install
新建一个准备当环境的文件夹pipenvtest,并cd进入该文件夹:
- pipenv --three 会使用当前系统的python3创建环境
- pipenv --python 3.6 指定某一python版本创建环境
- pipenv shell 激活虚拟环境
- pipenv --where 显示目录信息 /home/jiahuan/pipenvtest
- pipenv --venv 显示虚拟环境信息 /home/jiahuan/.local/share/virtualenvs/pipenvtest-9kkrh3ow
- pipenv --py 显示python解释器信息 /home/jiahuan/.local/share/virtualenvs/pipenvtest-9kkrh3ow/bin/python
- pipenv install requests 安装相关模块并加入到pipfile
- pipenv install django==1.11 安装固定版本模块并加入到pipfile
- pipenv graph 查看目前安装的库及其依赖
pipenv check检查安全漏洞
pipenv uninstall --all 卸载全部包并从pipfile中移除
如对本文有疑问,请在下面进行留言讨论,广大热心网友会与你互动!! 点击进行留言回复
python求numpy中array按列非零元素的平均值案例
网友评论