Skip to content

Commit

Permalink
Merge pull request #10 from Islandora/adam-vessey-patch-1
Browse files Browse the repository at this point in the history
Allow newer Drush for newer Drupal
  • Loading branch information
rosiel authored Jun 8, 2022
2 parents 68e91c3 + 939af57 commit a83140f
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions travis_setup_drupal.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,19 @@ fi
composer require "drupal/core-dev:$DRUPAL_VERSION"
DRUPAL_MAJOR=$(echo "$DRUPAL_VERSION" | cut -d. -f1)
if [ $DRUPAL_MAJOR -ge 9 ]; then
composer require phpspec/prophecy-phpunit:^2
# XXX: 9.4.x-dev installs phpunit 8... but then we expect to have to install
# the phpspec/prophecy-phpunit:^2 thing, which only works with phpunit 9.
composer require -W phpunit/phpunit:^9
composer require phpspec/prophecy-phpunit:^2 drush/drush
elif [ $DRUPAL_MAJOR -eq 8 ]; then
composer require drush/drush:^10
elif [ $DRUPAL_MAJOR -eq 7 ]; then
composer require drush/drush:^8
else
echo "Unmapped major version of Drupal: $DRUPAL_MAJOR"
exit 1
fi
composer require drush/drush=~10

echo "Setup Drush"
sudo ln -s /opt/drupal/vendor/bin/drush /usr/bin/drush
phpenv rehash
Expand Down

0 comments on commit a83140f

Please sign in to comment.