一、官網下載壓縮包並解壓。

官網:https://pypi.org/project/pip/#files

檔案:選擇.tar.gz版本

image

解壓後,進入解壓檔案目錄,在當前路徑下開啟cmd視窗

image

輸入:python setup.py install

安裝完成。

二、windows環境下永久修改pip映象源的方法

(1)在windows檔案管理器中,輸入 %APPDATA%

(2)會定位到一個新的目錄下,在該目錄下新建pip資料夾,然後到pip資料夾裡面去新建個pip.ini檔案

image

(3)在新建的pip.ini檔案中輸入以下內容

#豆瓣源
[global]
timeout =6000
index-url = https://pypi.douban.com/simple
trusted-host = pypi.douban.com #清華源
[global]
timeout =6000
index-url = https://pypi.tuna.tsinghua.edu.cn/simple/
trusted-host = pypi.tuna.tsinghua.edu.cn #阿里源
[global]
timeout =6000
index-url = https://mirrors.aliyun.com/pypi/simple/
trusted-host = mirrors.aliyun.com

注意:配置檔案中那個中文註釋一定要刪除哦,要不然識別不了。

四、cmd視窗執行

pip list