python, pipenv
HOME 下创建 .pip 文件夹, 再创建 pip.conf 文件, 内容如下:
[global]
timeout = 60
index-url = https://pypi.douban.com/simple
trusted-host = pypi.douban.com
if you want to enable this when you run command under admin permission, say: sudo pip install XX,
put this file under '/etc/pip.conf'
also, you can use it in this way to avoid add to 'etc' folder
# this is pretty cool, should be what I want.
pip install --user xxxxx
Install by special the source:
sudo pip install -i https://pypi.douban.com/simple/ flask
更多内容参见官方文档