提示:扫一扫查出行【扫一扫了解最新限行尾号】复制提示 方法一:
修改文件 ~/.pydistutils.cfg为:
[easy_install]
index_url = http://pypi.douban.com/simple
方法二:
直接在setup.py的同目录放置一个setup.cfg:
[easy_install]
index_url = http://pypi.douban.com/simple
结:
加上配置后python setup.py install安装的时候,依赖就会从douban的源下载了。
转自:http://everet.org/python-pypi-source.html