设置默认镜像源:
下次直接 pip install 就可以了不用加镜像源了
# 设置清华镜像源(示例)
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
pip config set global.trusted-host pypi.tuna.tsinghua.edu.cn
查看默认镜像源:
pip config list
删除默认镜像源:
# 删除全局镜像源配置
pip config unset global.index-url
# 删除镜像源的域名
pip config unset global.trusted-host
主波在之前设置默认的镜像源之后,有一次下载,找了半天怎么删除默认的,费劲了,希望能帮助到大家
默认镜像源:
官方的默认镜像源:说实话 下载很慢奥,可以用下面的镜像源下载很快的
https://pypi.org/simple
ex:要下载doccano :
pip install doccano -i https://pypi.tuna.tsinghua.edu.cn/simple
阿里云:
https://mirrors.aliyun.com/pypi/simple/
中科大:
https://pypi.mirrors.ustc.edu.cn/simple/
腾讯云:
https://mirrors.cloud.tencent.com/pypi/simple/
清华大学:
https://mirrors.tuna.tsinghua.edu.cn/
镜像源的选择:
我是换着用,哪个能用用哪个