Drush 9 (coming soon!) only supports one install method. It requires that your Drupal 8 site be built with Composer and Drush be listed as a dependency.
See the Drush 8 docs for installing prior versions of Drush.
Install a site-local Drush
- It is recommended that Drupal 8 sites be built using Composer, with Drush listed as a dependency. That project already includes Drush in its composer.json. If your Composer project doesn't yet depend on Drush, run
composer require drush/drushto add it.
- To run Drush, navigate to your Drupal root and call
- If you want the convenience of calling
../vendor/bin/drush, copy the examples/drush.wrapper file to your Drupal root and modify to taste.
- If you want the old convenience of being able to call
drushfrom anywhere, see drush-shim.
- See Usage for details on using Drush.
- To use a non-default PHP, edit ~/.bashrc so that the right PHP is in your $PATH.
|Drush Version||Drush Branch||PHP||Compatible Drupal versions||Code Status|
|Drush 8||8.x||5.4.5+||D6, D7, D8|
|Drush 7||7.x||5.3.0+||D6, D7|
|Drush 6||6.x||5.3.0+||D6, D7||Unsupported|
|Drush 5||5.x||5.2.0+||D6, D7||Unsupported|