Last updated January 23, 2013. Created by yurtboy on July 7, 2012.
Edited by claudinec, Andrew Agrios. Log in to edit this page.
Drush can be installed on a Mac using the Homebrew package manager, or manually using the following steps.
Download and unpack Drush
Download either the tar.gz or zip file from the Drush project page and unpack it into your home directory or a directory below your home directory. For example, if your home directory is /Users/myusername, unpacking the tar.gz or zip file there will create a folder /Users/myusername/drush.
Tell OS X where to find Drush
To tell your system where to find the Drush program, you can either:
- add the directory where Drush was downloaded to your PATH by updating your Bash or Zsh profile; or
- create a symbolic link from the Drush program to a directory in your PATH.
Add Drush directory to your PATH
The PATH shell variable tells OS X where to find programs that are run from the command line. You can update your PATH by editing the file .bash_profile (if you are using the Bash shell) or .zprofile (if you are using Zsh). These files are hidden files (name beginning with a dot) so they will usually not appear in the Finder.
To edit the profile file with the Nano text editor, open Terminal and type
nano ~/.bash_profile
and add the following line to the end of the file:
export PATH=$PATH:/Users/myusername/drush
Replace /Users/myusername/drush with the name of the directory where you unpacked Drush.
Symbolic link
In terminal:
cd /usr/binln -s /Users/myusername/drush/drush
(See video: http://youtu.be/TCg02d4am_Q)