轉自:http://blog.csdn.net/u012905422/article/details/53340260

对于python2.7版本,很多教程(如http://stackoverflow.com/questions/4750806/how-do-i-install-pip-on-windows)均让去https://pypi.python.org/pypi/pip#downloads官网下载pip的安装文件get-pip.py,但是自己去试出来各种各样的问题。因此还是简单mark一下吧。当然最简单的方法还是直接安装anaconda,那真是多快好省。。。这里不细说。喜欢一步步来感受中间按照的软件的,还是可以一个一个工具来安。

1、首先确认安装好python文件,并配置好环境变量

随处打开终端,输入 python ,可以运行,则说明ok,如下:

2、安装easy_install工具

下载easy_install工具安装文件,地址:https://bootstrap.pypa.io/ez_setup.py

在终端输入: python ez_setup.py

安装完后,可以在python安装目录下,Scripts文件夹内看到easy_install工具

3、用easy_install工具,安装 pip

Scripts文件夹内打开终端,运行: easy_install pip ,安装好后在该文件夹终端下运行pip如下:

## 对于 Linux
sudo pip install sth
# 或者明确版本
sudo pip2 install sth sudo pip3 install sth
sudo python2 -m pip install sth
sudo /path/to/python -m pip install sth ##
 
对于 Windows NT ## #
如果仅安装 python2
pip install sth
# 如果安装有 python3, 则需要明确 pip 版本
py -2 -m pip install sth
py -3 -m pip install sth
$ python -V
Python 2.7.10
$ python3 -V
Python 3.5.2

可以使用:

$ python -m pip install requests
$ python3 -m pip install requests

或者使用:

$ pip install requests
$ pip3 install requests

http://blog.csdn.net/u012905422/article/details/53340260的更多相关文章

  1. http://blog.csdn.net/java2000_wl/article/details/8627874

    http://blog.csdn.net/java2000_wl/article/details/8627874

  2. android 蓝牙 http://blog.csdn.net/u012843100/article/details/52384219

    http://blog.csdn.net/u012843100/article/details/52384219

  3. http://blog.csdn.net/krislight/article/details/9391455

    http://blog.csdn.net/krislight/article/details/9391455

  4. http://blog.csdn.net/shawnkong/article/details/52045894

    http://blog.csdn.net/shawnkong/article/details/52045894

  5. 使用C++扩展Python的功能 转自:http://blog.csdn.net/magictong/article/details/8897568#comments

    使用C++扩展Python的功能 环境 VS2005Python2.5.4 Windows7(32位) 简介 长话短说,这里说的扩展Python功能与直接用其它语言写一个动态链接库,然后让Python ...

  6. http://blog.csdn.net/hitmediaman/article/details/6636402

    http://blog.csdn.net/hitmediaman/article/details/6636402

  7. http://blog.csdn.net/iamshaofa/article/details/7877785/

    http://blog.csdn.net/iamshaofa/article/details/7877785/

  8. http://blog.csdn.net/z69183787/article/details/37819831

    http://blog.csdn.net/z69183787/article/details/37819831

  9. http://blog.csdn.net/u010246789/article/details/52539576

    http://blog.csdn.net/u010246789/article/details/52539576

随机推荐

  1. Handler使用小结

    个人概念里面handler用来更新UI.一直有一个问题困恼我,为什么我在主线程里面创建一个Handler不需要传递传递Looper,而在一个子线程里面必须调用Looper.prepare, Loope ...

  2. Oracle入门之表结构的管理

    建表的基本语法: create table table_name( field1 datatype, field1 datatype, field1 datatype, ... ) 注:table_n ...

  3. browser_action' is only allowed for extensions but this is a legacy packaged app

    manifest.json中不可包含调试代码:    "app": {     "launch": {      "local_path": ...

  4. 软件测试:第二次作业(JUnit单元测试方法)

    一.JUnit是什么? JUnit是由 Erich Gamma 和 Kent Beck 编写的一个回归测试框架(regression testing framework).JUnit测试是程序员测试, ...

  5. Curve 曲线 工具

    最近研究了曲线绘制的工具,主要是2D方程的绘制.综合了许多工具,完成了一下两个脚本. 绘制的工具: using UnityEngine; using System.Collections; using ...

  6. Python05(运算符)

    Trainning-day04回顾1.Python运算符 + - * / % ** //2.标准输入函数 input() input("输入提示语")3.占位符 生成一定格式的字符 ...

  7. mysql知识点拾遗梳理

    mysql卸载重装过程: sudo apache2ctl stop sudo apt-get --purge remove mysql-client mysql-server mysql-common ...

  8. poi读取excel工具类

    package com.manage.utils; import ch.qos.logback.core.net.SyslogOutputStream; import com.google.gson. ...

  9. 学习小片段——springboot 错误处理

    一:先看看springboot默认的错误处理机制 springboot默认会判断是否是浏览器(http请求头Accept是否含有 text/html)来选择返回html错误页面或json错误信息 原因 ...

  10. Power BI 3-4月功能更新培训合集

    ​Power BI 3-4月功能更新培训合集 Power BI每月功能的更新,都有很多大咖精辟解读,我们一直也都是积极中期待,相信所有P友如是或更甚. 视频学习可以结合微软Power BI 3-4月文 ...