简体   繁体   中英

Installing pip for Python 3.4 - Mac OS X

as you know the Mac comes with Python pre-installed, mine has the 2.7 version. I installed Python 3.4. I installed pip using the command sudo easy_install however it gets installed to the 2.7 version of Python and all the packages i download therefore get installed to the 2.7 version. Is there a way to install pip to the Python 3.4 version? Thank you in advance!

I installed Python 3.4 for my Mac from this page:

https://www.python.org/download/

It installed pip automatically, but it's called pip3 , not pip . Type which pip3 at the console to find it.

If you're not averse to using a third-party package manager, the easiest way I've found to deal with 3.x on OS X is to use Homebrew . You can maintain custom 2.x and 3.x installations (with pip and pip3 and everything else) alongside the system 2.7 installation with no problems.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM