Back

python - pip - windows下的pip使用proxy

发布时间: 2023-01-02 07:10:00

refer to:
https://stackoverflow.com/questions/43473041/how-to-configure-pip-per-config-file-to-use-a-proxy-with-authentification

发现没有代理真的不行。今天想要下载个东西,20k每秒。一个中午没下好。

1. 创建文件:

C:\Users\<username>\AppData\Roaming\pip\pip.ini

2. 内容为:

[global]
proxy = http://user:password@proxy_name:port

例如:
[global]
proxy = http://localhost:8080

3. 保存该文件,然后正常运行pip 命令即可。

对比一下速度吧,非常爽

Back