美文网首页python
pip使用国内源

pip使用国内源

作者: _沉默的疯子 | 来源:发表于2019-12-16 16:53 被阅读0次

新版ubuntu要求使用https源,要注意。

清华:https://pypi.tuna.tsinghua.edu.cn/simple

阿里云:http://mirrors.aliyun.com/pypi/simple/

中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/

华中理工大学:http://pypi.hustunique.com/

山东理工大学:http://pypi.sdutlinux.org/

豆瓣:http://pypi.douban.com/simple/

临时使用:

可以在使用pip的时候加参数-i https://pypi.tuna.tsinghua.edu.cn/simple

例如:pip install -i https://pypi.tuna.tsinghua.edu.cn/simple pyspider,这样就会从清华这边的镜像去安装pyspider库。

永久修改,一劳永逸:

Linux下,修改 ~/.pip/pip.conf (没有就创建一个文件夹及文件。文件夹要加“.”,表示是隐藏文件夹)

内容如下:

[global]
index-url = https://pypi.tuna.tsinghua.edu.cn/simple
[install]
trusted-host=mirrors.aliyun.com

windows下,直接在user目录中创建一个pip目录,如:C:\Users\xx\pip,新建文件pip.ini。内容同上。

相关文章

  • python使用国内源

    1、常用国内源 2、临时使用国内源 3、全局使用国内源 命令运行完成后,pip.conf中内容为: 4、pip c...

  • pip更换国内源

    Python pip更换国内源 国内源 常用的国内源 linux更换操作 创建这个文件并输入以下内容~/.pip/...

  • pip使用国内源

    安装 Pulp 等包时遇到问题 在安装一个不是很常用的python库时 遇到了长时间无法下载安装的问题,之前也有配...

  • pip 使用国内源

    阿里云http://mirrors.aliyun.com/pypi/simple/ 中国科技大学https://p...

  • pip使用国内源

    新版ubuntu要求使用https源,要注意。 清华:https://pypi.tuna.tsinghua.edu...

  • pip 使用国内源

    https://www.cnblogs.com/microman/p/6107879.html

  • pip、conda 设置国内源

    pip conda 添加国内源 1.pip 设为全局默认 其他国内镜像 pip临时使用国内镜像源 2.conda ...

  • 使用Flask工具包flask-sqlacodegen生成ORM

    一、pip安装flask工具包flask-sqlacodegen pip使用pypi国内源,下载速度会比较快,这边...

  • 解决pip install 下载慢

    更改pip源即可,修改为pip国内源: 新版ubuntu要求使用https源,要注意。 清华:https://py...

  • python相关指令

    pip国内源加速 可以在使用pip的时候在后面加上-i参数,指定pip源 pip国内的一些镜像 阿里云 https...

网友评论

    本文标题:pip使用国内源

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