Install Drush

This whole section deprecated as drush is installed with drupal - see instructions for installation of Drupal which has been edited to install via composer

The version of php installed on my server is 5.4

I would have liked to upgrade it, but the repo it was installed from (base) only has 5.4, and as I am only using Drupal 7 on this server, I left it as it was.

This does mean though that I am restricted to Drush7 too.

So I installed Drush with Composer.

First install Composer:

# cd /opt
# wget
# php installer
# ln -s /opt/composer.phar /usr/local/bin/composer
# rm installer

Next install Drush7 globally using Composer:

# mkdir /opt/drush
# cd /opt/drush
# composer init --require=drush/drush:7.* -n
# composer config bin-dir /usr/local/bin
# composer install

To update Drush in future, :

# cd /opt/drush
# composer update