如何为python 2.6安装pip? [英] How to install pip for python 2.6?

查看:535
本文介绍了如何为python 2.6安装pip?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试按照此答案中的说明进行操作,但是easy_install-2.6找不到pip:

I tried following the instructions from this answer but easy_install-2.6 could not find pip:

>sudo easy_install-2.6 pip
Processing pip
error: Not a recognized archive type: pip

如何为python 2.6安装pip?

How do I install pip for python 2.6?

推荐答案

只需按照说明

  • 安全下载 get-pip.py (这是2.6专用文件,来自Ricardo Iramar的 answer )的链接.
  • 在您保存的目录get-pip.py中,运行

    1. Securely download get-pip.py (this is the 2.6-specific file, link from Ricardo Iramar's answer).
    2. In the directory you saved get-pip.py, run

    sudo python2.6 get-pip.py
    

    ,您将大功告成.

    这将为Python 2.6安装pip,并且不会影响您的2.7版安装.

    This will install pip for Python 2.6, and won't touch your version 2.7 installation.

    这篇关于如何为python 2.6安装pip?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

  • 查看全文
    登录 关闭
    扫码关注1秒登录
    发送“验证码”获取 | 15天全站免登陆