Installing Django on Mavericks Mac Os X (Simple install for development)

I was having a real problem installing Django and mySql on a mac, there were lots of guides but many of them wanted you to install another version of Python and stuff like virtualenv! The following commands are what I finally used to get it all installed using mainly homebrew. Hope this saves someone a lot of time and messing around and having to wipe their mac to clean off bad previous installs etc.

 

Open a terminal and Install Homebrew! (Updated)

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

then

brew doctor

Install Pip

sudo easy_install pip

Install Django

sudo pip install django

Install mySQL and mysql python module

brew install mysql

sudo pip install MySQL-python

Other useful Commands

To Start mySQL (Remember to change the root password)

/usr/local/bin/mysql.server start

Check Django Version

python -c “import django; print(django.get_version())”

Advertisements