pip 修改镜像源为豆瓣源

2023-05-29,,

1. 修改配置文件

编辑配置文件,如果没有则新建:

$ vi ~/.pip/pip.conf

添加内容如下:

[global]
index-url = https://pypi.doubanio.com/simple

2. 命令行选项

使用 pip 命令安装扩展包时指定源:

$ pip install SQLAlchemy -i https://pypi.doubanio.com/simple

参考链接:

    pip修改官方源为豆瓣源 | cls1991的个人博客
    pip 更换软件镜像源 - 简书

pip 修改镜像源为豆瓣源的相关教程结束。

《pip 修改镜像源为豆瓣源.doc》

下载本文的Word格式文档,以方便收藏与打印。