Skip to content

Instantly share code, notes, and snippets.

@sadanandkenganal
Last active May 9, 2016 04:25
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sadanandkenganal/a7ce309deeb1f4bf35dd to your computer and use it in GitHub Desktop.
Save sadanandkenganal/a7ce309deeb1f4bf35dd to your computer and use it in GitHub Desktop.
Installing Drush on Mac

Steps to install

  1. From the URL https://github.com/drush-ops/drush, clone or download the zip file.
  2. Make sure to check the 'Drupal Compatability' here http://docs.drush.org/en/master/install/?highlight=versions.
  3. Put into home folder and extract it.
  4. Rename folder as drush.
  5. Drush now requires Composer in order to install its dependencies and autoload classes.
  6. If you don't have composer run below commands or else skip this step.
In terminal:
curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/bin/composer

7 . From the drush directory run composer install.

composer install

8 . 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.

Alternative export path would be:

export PATH="$HOME/drush:$PATH"

10 . Run below command.

source ~/.bash_profile

11 . Test drush --version

@vidhyashekar
Copy link

Very helpful. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment