PIP换源

jupiter
2022-11-17 / 0 评论 / 339 阅读 / 正在检测是否收录...
温馨提示:
本文最后更新于2022年11月17日,已超过525天没有更新,若内容或图片失效,请留言反馈。

PIP换源

1.临时换源

使用-i参数指定临时源,任选一个即可

#清华源
pip3 install markdown -i https://pypi.tuna.tsinghua.edu.cn/simple
#阿里源
pip3 install markdown -i https://mirrors.aliyun.com/pypi/simple/
#腾讯源
pip3 install markdown -i https://mirrors.cloud.tencent.com/pypi/simple
#豆瓣源
pip3 install markdown -i https://pypi.douban.com/simple/

2.永久换源

#清华源
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
#阿里源
pip config set global.index-url https://mirrors.aliyun.com/pypi/simple/
#腾讯源
pip config set global.index-url https://mirrors.cloud.tencent.com/pypi/simple
#豆瓣源
pip config set global.index-url https://pypi.douban.com/simple/
#换回默认源
pip config unset global.index-url
0

评论 (0)

打卡
取消