美文网首页
Mac 下安装pip

Mac 下安装pip

作者: 終于 | 来源:发表于2017-08-30 12:01 被阅读0次

    pip是python的包管理工具,准备写爬虫所以安装下。

    Step1.brew install pip(不能下载)

    Updating Homebrew...

    ==> Auto-updated Homebrew!

    Updated 1 tap (homebrew/core).

    ==> Updated Formulae

    couchdb                      dcos-cli                      fobis                        kube-aws                      libpng                        m-cli                        mmark                        thefuck                      vips

    Error: Could not link:

    /usr/local/share/doc/homebrew

    Please delete these paths and run `brew update`.

    ==> Migrating HOMEBREW_REPOSITORY (please wait)...

    Error: /usr/local/Homebrew already exists.

    Please remove it manually or uninstall and reinstall Homebrew into a new

    location as the migration cannot be done automatically.

    Error: No available formula with the name "pip"

    Homebrew provides pip via: `brew install python`. However you will then

    have two Pythons installed on your Mac, so alternatively you can install

    pip via the instructions at:

    https://pip.readthedocs.io/en/stable/installing/

    可以看出pip是跟着python一起安装的。

    Step2.使用easy_install 安装pip

    由于我当前的python版本是mac自带的2.7.10,所以找到easy_install 安装pip:

    sudo python /usr/bin/easy_install-2.7 pip

    相关文章

      网友评论

          本文标题:Mac 下安装pip

          本文链接:https://www.haomeiwen.com/subject/zbnzdxtx.html