pip常用記錄


同電腦多版本python

python2 -m pip install 包名(python2指向2.7的python.exe)

 

指定版本

pip install 包名==版本號

 

指定源

pip install receive http://mirrors.aliyun.com/pypi/simple/

某些包可能因為被牆,或者某個源沒有,可以嘗試指定其他源安裝

 

pip常用源

  1. 阿里雲 http://mirrors.aliyun.com/pypi/simple/
  2. 中國科技大學 https://pypi.mirrors.ustc.edu.cn/simple/
  3. 豆瓣 (douban) http://pypi.douban.com/simple/
  4. 清華大學 https://pypi.tuna.tsinghua.edu.cn/simple/
  5. 中國科學技術大學 http://pypi.mirrors.ustc.edu.cn/simple/
C:\Users\user\Desktop\web_py>python2 -m pip install receive http://mirrors.aliyun.com/pypi/simple/
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
Collecting http://mirrors.aliyun.com/pypi/simple/
  Downloading http://mirrors.aliyun.com/pypi/simple/ (7.6MB)
    100% |████████████████████████████████| 7.6MB 55kB/s
  Cannot unpack file c:\users\user\appdata\local\temp\pip-unpack-zc4dwk\simple.html (downloaded from c:\users\user\appdata\local\temp\pip-req-build-v59wki, content-type: text/html); cannot detect archive format
Cannot determine archive format of c:\users\user\appdata\local\temp\pip-req-build-v59wki

C:\Users\user\Desktop\web_py>python2 -m pip install receive https://pypi.mirrors.ustc.edu.cn/simple/
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
Collecting https://pypi.mirrors.ustc.edu.cn/simple/
  Downloading https://pypi.mirrors.ustc.edu.cn/simple/ (7.7MB)
    100% |████████████████████████████████| 7.7MB 547kB/s
  Cannot unpack file c:\users\user\appdata\local\temp\pip-unpack-qm3x7w\simple (downloaded from c:\users\user\appdata\local\temp\pip-req-build-tvbhov, content-type: text/html; charset=UTF-8); cannot detect archive format
Cannot determine archive format of c:\users\user\appdata\local\temp\pip-req-build-tvbhov
View Code

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM