Skip to content

Instantly share code, notes, and snippets.

@RainbowArray
Last active June 16, 2016 19:07
Show Gist options
  • Save RainbowArray/d5b60e53dd8f45083b66d324451e4848 to your computer and use it in GitHub Desktop.
Save RainbowArray/d5b60e53dd8f45083b66d324451e4848 to your computer and use it in GitHub Desktop.
Drupal 8 composer with Pantheon
{
"name": "",
"description": "Constructing Drupal 8 docroot with upstream drops-8 updates",
"type": "project",
"license": "GPL-2.0+",
"authors": [
{
"name": "",
"email": ""
}
],
"repositories": [
{
"type": "composer",
"url": "https://packages.drupal.org/8"
}
],
"require": {
"composer/installers": "^1.0.20",
"drupal-composer/drupal-scaffold": "^2.0.1",
"cweagans/composer-patches": "~1.0",
"drupal/core": "~8.0",
"drupal/console": "~0.10",
"drush/drush": "~8.0",
"drupal/amp": "1.0.0-beta4",
"drupal/metatag": "1.0.0-beta5",
"drupal/token": "1.0.0-alpha2"
},
"require-dev": {
"behat/mink": "~1.7",
"behat/mink-goutte-driver": "~1.2",
"jcalderonzumba/gastonjs": "~1.0.2",
"jcalderonzumba/mink-phantomjs-driver": "~0.3.1",
"mikey179/vfsStream": "~1.2",
"phpunit/phpunit": "~4.8",
"symfony/css-selector": "~2.8",
"pantheon-systems/circle-scripts": "*"
},
"minimum-stability": "dev",
"prefer-stable": true,
"autoload": {
"classmap": [
"scripts/composer/ScriptHandler.php"
]
},
"scripts": {
"drupal-scaffold": "DrupalComposer\\DrupalScaffold\\Plugin::scaffold",
"post-install-cmd": [
"DrupalProject\\composer\\ScriptHandler::createRequiredFiles",
"scripts/drupal-settings.sh"
],
"post-update-cmd": [
"DrupalProject\\composer\\ScriptHandler::createRequiredFiles"
]
},
"config": {
"bin-dir": "bin/"
},
"extra": {
"installer-paths": {
"web/core": ["type:drupal-core"],
"web/modules/contrib/{$name}": ["type:drupal-module"],
"web/profiles/contrib/{$name}": ["type:drupal-profile"],
"web/themes/contrib/{$name}": ["type:drupal-theme"],
"drush/contrib/{$name}": ["type:drupal-drush"]
},
"drupal-scaffold": {
"source": "https://raw.githubusercontent.com/pantheon-systems/drops-8/{version}/{path}",
"includes": [
"sites/default/settings.php",
"sites/default/settings.pantheon.php"
]
}
}
}
@RainbowArray
Copy link
Author

This is an example of a composer.json file that can be used to build a Drupal docroot containing upstream updates from drops-8 for Pantheon-specific files. Useful for a continuous integration workflow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment