Composer tips and tricks with Drupal 8 and Drush 9

Attachment Size
PHPComposer.pdf 505.14 KB

PHP Composer Overview

Remove old versions, I removed the conflicts with the following commands:

$ composer global remove drush/drush
$ composer global remove package/package

Install Drush with Composer

$ composer require drush/drush:9.*

You can query Composer to find where it has set the user $COMPOSER_HOME directory.

composer config --list --global

To update to a newer version 

composer global update

  • Run composer install for a new project or composer update for an existing one. Do so from the same directory as composer.json.