美文网首页简友广场Python学习笔记
如何使用清华大学开源镜像站下载相关python第三方库

如何使用清华大学开源镜像站下载相关python第三方库

作者: LeafMa | 来源:发表于2021-01-23 22:04 被阅读0次

临时使用

pip install -i https://pypi.tuna.tsinghua.edu.cn/simple some-package

注意,simple 不能少, 是 https 而不是 http

设为默认

升级 pip 到最新的版本 (>=10.0.0) 后进行配置:

pip install pip -U

pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple

如果您到 pip 默认源的网络连接较差,临时使用本镜像站来升级 pip:

pip install -i https://pypi.tuna.tsinghua.edu.cn/simple pip -U

来源:https://mirrors.tuna.tsinghua.edu.cn/help/pypi/

相关文章

网友评论

    本文标题:如何使用清华大学开源镜像站下载相关python第三方库

    本文链接:https://www.haomeiwen.com/subject/pcevzktx.html