linux 配置 pip 换源

Posted _刘文凯_

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了linux 配置 pip 换源相关的知识,希望对你有一定的参考价值。

linux 配置 pip 换源, Linux如何换pip源

进入用户目录下,并建立.pip文件夹:

cd ~
mkdir .pip
cd .pip
vim pip.conf

然后按i变成插入模式,输入:

[global]
trusted-host =  mirrors.aliyun.com
index-url = http://mirrors.aliyun.com/pypi/simple

按ESC推出插入模式,按shift+: 进入命令模式,然后输入wq 回车

以上是关于linux 配置 pip 换源的主要内容,如果未能解决你的问题,请参考以下文章