pip使用简介

pip命令

pip的意思是破蛋而出,继承了python的思维,呵呵~python的包有以egg命名的,意思是蛇蛋,如此便自然而然的明白如此命名的原因。


pip用来安装和管理python包的命令,可以代替easy_install。

用法:

1、安装python包

$ pip install simplejson
[... progress report ...]
Successfully installed simplejson
2、升级包

$ pip install --upgrade simplejson
[... progress report ...]
Successfully installed simplejson
3、删除包
$ pip uninstall simplejson
Uninstalling simplejson:
  /home/me/env/lib/python2.7/site-packages/simplejson
  /home/me/env/lib/python2.7/site-packages/simplejson-2.2.1-py2.7.egg-info
Proceed (y/n)? y
  Successfully uninstalled simplejson

4、从指定文件中安装指定的包、模块

pip install -r requirements.txt

requirements.txt中的格式是:

django-coverage==1.2.2
django-permissions==1.0.3
django-workflows==1.0.2
django==1.3.1
MySQL-python==1.2.3
python-krbV==1.0.90
South==0.7.5


关于pip的更多详细信息,请见http://www.pip-installer.org/en/latest/

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值