python - easy_install的安装和使用

easy_install介绍


正常情况下,我们要给Python安装第三方的扩展包,我们必须下载压缩包,解压缩到一个目录,然后命令行或者终端打开这个目录,然后执行python setup.py install来进行安装。
这样是不是很繁琐呢?如果我们直接命令行执行easy_install Twisted
就把最新版的Twisted包装上去了,是不是很爽呢?
所以easy_install就是为了我们安装第三方扩展包更容易。

按装easy_install


首先下载easy_install的安装包,下载地址:
[]#wget http://pypi.python.org/packages/source/s/setuptools/setuptools-0.6c11.tar.gz#md5=7df2a529a074f613b509fb44feefe74e –no-check-certificate
[]#tar -zxvf setuptools-0.6c11.tar.gz
[]#cd setuptools-0.6c11
[]#python setup.py install
[]#cd ../python2.7/site-packages/
[]#sh setuptools-0.6c11-py2.7.egg
Processing setuptools-0.6c11-py2.7.egg
setuptools 0.6c11 is already the active version in easy-install.pth
Installing easy_install script to /usr/local/python2.7/bin
Installing easy_install-2.7 script to /usr/local/python2.7/bin
Installed /usr/local/python2.7/lib/python2.7/site-packages/setuptools-0.6c11-py2.7.egg
Processing dependencies for setuptools==0.6c11
Finished processing dependencies for setuptools==0.6c11
[]#ln -s /usr/local/python2.7/bin/easy_install /usr/local/bin/easy_install
[]#easy_install -h

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值