Python replaces domestic pip source under windows
foreword
Under Windows, when using the pip install command, the following situation occurs: The
corresponding server connection fails . In this case, the pip source can be replaced
Replace Windows source
Enter the directory under Windows
C:\Users\计算机用户名
Create a new folder for pip
, enter the pip folder, create a new TXT text file, name it pip.ini,
edit the "pip.ini" file, and add the following content:
Ali source:
[global]
index-url = http://mirrors.aliyun.com/pypi/simple/
[install]
trusted-host = mirrors.aliyun.com
University of Science and Technology of China
[global]
index-url = https://pypi.mirrors.ustc.edu.cn/simple/
[install]
trusted-host = pypi.mirrors.ustc.edu.cn
Tsinghua University Source
[global]
index-url = https://pypi.tuna.tsinghua.edu.cn/simple/
[install]
trusted-host = mirrors.tsinghua.com
Doubanyuan
[global]
index-url = http://pypi.douban.com/simple/
[install]
trusted-host = mirrors.douban.com
save after modification
test
pip install pyinstaller
success! ! !