diff --git a/.travis.yml b/.travis.yml index 5a3b11b9ba..ac51e49242 100644 --- a/.travis.yml +++ b/.travis.yml @@ -29,15 +29,12 @@ install: script: - if [[ $RELEASE = dev ]]; then composer --verbose remove --no-update drupal/console; fi; - - if [[ $RELEASE = dev ]]; then composer --verbose require --no-update drupal/core:8.8.x-dev webflo/drupal-core-require-dev:8.8.x-dev; fi; + - if [[ $RELEASE = dev ]]; then composer --verbose require --no-update drupal/core:8.8.x-dev; composer --verbose require --no-update --dev drupal/core-dev:8.8.x-dev; fi; - if [[ $RELEASE = dev ]]; then composer --verbose update; fi; - - cd $TRAVIS_BUILD_DIR/web - - ./../vendor/bin/drush site-install --verbose --yes --db-url=sqlite://tmp/site.sqlite - - ./../vendor/bin/drush runserver $SIMPLETEST_BASE_URL & + - ./vendor/bin/drush site-install --verbose --yes --db-url=sqlite://tmp/site.sqlite + - ./vendor/bin/drush runserver $SIMPLETEST_BASE_URL & - until curl -s $SIMPLETEST_BASE_URL; do true; done > /dev/null - # Skip core/tests/Drupal/Tests/ComposerIntegrationTest.php because web/ has no composer.json - # Ignore PageCache group temporarily, @see https://www.drupal.org/node/2770673 - # Ignore Setup group temporarily, @see https://www.drupal.org/node/2962157 - - ./../vendor/bin/phpunit -c core --testsuite unit --exclude-group Composer,DependencyInjection,PageCache,Setup - - ./../vendor/bin/drush - - if [[ $RELEASE = stable ]]; then ./../vendor/bin/drupal; fi; + # Run a single unit test to verfiy the testing setup. + - ./vendor/bin/phpunit -c ./web/core ./web/core/modules/system/tests/src/Unit/SystemRequirementsTest.php + - ./vendor/bin/drush + - if [[ $RELEASE = stable ]]; then ./vendor/bin/drupal; fi; diff --git a/README.md b/README.md index 4f42497a2e..2c40e4384f 100644 --- a/README.md +++ b/README.md @@ -54,7 +54,7 @@ When installing the given `composer.json` some tasks are taken care of: ## Updating Drupal Core This project will attempt to keep all of your Drupal Core files up-to-date; the -project [drupal-composer/drupal-scaffold](https://github.com/drupal-composer/drupal-scaffold) +project [drupal/core-composer-scaffold](https://github.com/drupal/core-composer-scaffold) is used to ensure that your scaffold files are updated every time drupal/core is updated. If you customize any of the "scaffolding" files (commonly .htaccess), you may need to merge conflicts if any of your modified files are updated in a @@ -62,8 +62,8 @@ new release of Drupal core. Follow the steps below to update your core files. -1. Run `composer update drupal/core webflo/drupal-core-require-dev "symfony/*" --with-dependencies` to update Drupal Core and its dependencies. -1. Run `git diff` to determine if any of the scaffolding files have changed. +1. Run `composer update drupal/core drupal/core-dev --with-dependencies` to update Drupal Core and its dependencies. +2. Run `git diff` to determine if any of the scaffolding files have changed. Review the files for any changes and restore any customizations to `.htaccess` or `robots.txt`. 1. Commit everything all together in a single commit, so `web` will remain in @@ -91,7 +91,7 @@ workrounds if a project decides to do it anyway](https://getcomposer.org/doc/faq ### Should I commit the scaffolding files? -The [drupal-scaffold](https://github.com/drupal-composer/drupal-scaffold) plugin can download the scaffold files (like +The [Drupal Composer Scaffold](https://github.com/drupal/core-composer-scaffold) plugin can download the scaffold files (like index.php, update.php, …) to the web/ directory of your project. If you have not customized those files you could choose to not check them into your version control system (e.g. git). If that is the case for your project it might be convenient to automatically run the drupal-scaffold plugin after every install or update of your project. You can diff --git a/composer.json b/composer.json index 9b30b092c4..b29500cc0c 100644 --- a/composer.json +++ b/composer.json @@ -19,17 +19,16 @@ "php": ">=7.0.8", "composer/installers": "^1.2", "cweagans/composer-patches": "^1.6.5", - "drupal-composer/drupal-scaffold": "^2.5", "drupal/console": "^1.0.2", - "drupal/core": "^8.7.0", - "drush/drush": "^9.0.0", - "vlucas/phpdotenv": "^2.4", + "drupal/core": "^8.8.0", + "drupal/core-composer-scaffold": "^8.8.0", + "drush/drush": "^9.7.1 | ^10.0.0", + "vlucas/phpdotenv": "^4.0", "webflo/drupal-finder": "^1.0.0", - "webmozart/path-util": "^2.3", "zaporylie/composer-drupal-optimizations": "^1.0" }, "require-dev": { - "webflo/drupal-core-require-dev": "^8.7.0" + "drupal/core-dev": "^8.8.0" }, "conflict": { "drupal/drupal": "*" @@ -64,6 +63,11 @@ "patchLevel": { "drupal/core": "-p2" }, + "drupal-scaffold": { + "locations": { + "web-root": "web/" + } + }, "installer-paths": { "web/core": ["type:drupal-core"], "web/libraries/{$name}": ["type:drupal-library"], @@ -71,12 +75,6 @@ "web/profiles/contrib/{$name}": ["type:drupal-profile"], "web/themes/contrib/{$name}": ["type:drupal-theme"], "drush/Commands/contrib/{$name}": ["type:drupal-drush"] - }, - "drupal-scaffold": { - "initial": { - ".editorconfig": "../.editorconfig", - ".gitattributes": "../.gitattributes" - } } } } diff --git a/load.environment.php b/load.environment.php index 769343fd6f..eef1d28d07 100644 --- a/load.environment.php +++ b/load.environment.php @@ -11,10 +11,5 @@ /** * Load any .env file. See /.env.example. */ -$dotenv = new Dotenv(__DIR__); -try { - $dotenv->load(); -} -catch (InvalidPathException $e) { - // Do nothing. Production environments rarely use .env files. -} +$dotenv = Dotenv::createImmutable(__DIR__); +$dotenv->safeLoad();