Python modify pip source --- windows / Linux

Abstract python contact with more than half a year before the project, and most of the time to read a book in the company, most recently at last free to learn python at home, to write the code.
But it comes to python, we must say a python module, python from the code regardless of style or involve surface, what are spicy hot it's amazing.
Well, talking about third-party modules Download python, is bound to talk about pip, pip default source download speed is really not to force ah not to force. So pip modify the source of it.
Special attention, remember display name suffix Oh, do not hide the extension, then the surface of the display pip.ini actually pip.ini.txt. Ha ...............
the Linux pip modifying the source as follows:

Under linux, modify ~ / .pip / pip.conf (not create one),

Under windows, create a directory pip (small tips:% HOMEPATH% directory is the user oh ....) directly in the user directory, such as: C: \ Users \ KingUranus \ pip, the new file pip.ini

 

These configurations are once manner, if the temporary use, it can be set to the following:

pip -i http://pypi.douban.com/simple install selenium -- trusted-host pypi.douban.com

Well, although there are many within the company blog, but do not allow outgoing, it can only be started all over again ......
then it begins pip installation step by step Come on. . . . fighting !!!

Source: Huawei cloud community  Author: a dream seven years poem

 

Guess you like

Origin blog.csdn.net/devcloud/article/details/94720323