Brew Install Python 2.7

Brew Install Python 2.7

This post explains how to install a clean version of Python in a Mac OS X Mavericks/Yosemite.

Install Python on Mac system easily and quickly. This post will give a complete walk through of installing Python using brew and manual process. Python is one of the most commonly and widely used programming languages used by Data Engineers and Data Scientists. Since 1st March 2018 the python formula will be upgraded to Python 3.x, while a new email protected formula will be added for Python 2.7, specifically. See changes announcement here or the final doc about using Homebrew for Python here. For older Homebrew: For Python 2.x: brew install python For Python 3.x: brew install python3. If you installed python3 via a package manager like brew, you need to use the remove command from the package manager, for example, brew uninstall python3. Share Improve this answer. Install Python 2, enter: brew install [email protected] The system should respond with the version number, 2.7.9 and higher. Alternatively, you can install Python with pyenv. Install pyenv, enter pip install pyenv. Install Python, enter pyenv install, for example pyenv install 2.7.9. Check that the Python version was installed, by entering.

You’ll also learn to install and use the virtualenv and virtualenvwrapper tools to create virtual environments for your projects.

Install Xcode and Homebrew

Brew Install Python 2.7 Hon 2 7 On Linux Mint

First of all, install Xcode if you don’t have it already. You can find it in the Apple Store.

Next, we need to install the Command Line Tools of Xcode. Open a Terminal and type:

this should trigger a pop-up window that will ask you to install the Command Line Tools. If you have some trouble installing these tools, you might find useful this post on Stackoverflow.

Next, we need to install Homebrew. In the Terminal, type this command line:

Brew Install Python 2.7


you can activate these changes by typing


if your .bash_profile calls the .bashrc, as explained earlier.

Now, you can create a virtual environment by typing:

which will create the folder ~/.virtualenvs/myenvironment, and it will be initially active.

You can change from one virtual environment to another by just typing:

Deactivate an environment with

Delete an environment with

And list the existing environments with

You can find more useful commands here.

Wooha! Now you’re ready to start working on your Python projects! 😉

Was it useful? Don’t miss all the thins you can learn here!

Brew Install Python 2.7 Install

and please… give a g+1 and share!! Thanks! 🙂