Skip to content

Instantly share code, notes, and snippets.

@fubarhouse
Created October 6, 2017 11:30
Show Gist options
  • Save fubarhouse/8a615a2626b2627c259bde6cfb74f6be to your computer and use it in GitHub Desktop.
Save fubarhouse/8a615a2626b2627c259bde6cfb74f6be to your computer and use it in GitHub Desktop.
A working Drupal 7 composer.json build file
{
"name": "mynamespace/myproject",
"description": "Composer file example",
"repositories": [
{
"type": "composer",
"url": "https://packages.drupal.org/7/"
},
{
"type": "package",
"package": {
"name": "mynamespace/patches",
"version": "1.0.0",
"type": "patches",
"require": {
"netresearch/composer-patches-plugin": "~1.0"
},
"extra": {
"patches": {
"drupal/entityreference": {
"7.1.x-dev": {
"dc4196b4e97e11ff24e762d94864132e12daf7be": {
"title": "Allow skipping entity access check when rendering field",
"url": "https://www.drupal.org/files/issues/entityreference-skip-access-check-1967180-16.patch"
}
}
},
"drupal/features": {
"7.2.2":[
{
"title": "Remove mtime from .info export (added by Drupal 7.33)",
"url": "https://www.drupal.org/files/issues/2381739-features-mtime.patch"
}
]
},
"drupal/panels_bootstrap_styles": {
"7.1.0-alpha1":[
{
"title": "Bootstrap Panel Title uses div insteaad of h3 element - semantic issue",
"url": "https://www.drupal.org/files/issues/2228445-comment3-h3-panel-title.patch"
}
]
}
}
}
}
},
{
"type": "package",
"package": {
"name": "library/backbone",
"version": "1.0.0",
"type": "drupal-library",
"dist": {
"url": "https://github.com/jashkenas/backbone/archive/1.0.0.zip",
"type": "zip"
}
}
},
{
"type": "package",
"package": {
"name": "library/underscore",
"version": "1.5.2",
"type": "drupal-library",
"dist": {
"url": "https://github.com/jashkenas/underscore/archive/1.5.2.zip",
"type": "zip"
}
}
},
{
"type": "package",
"package": {
"name": "drupal/clean_markup",
"version": "7.2.7",
"type": "drupal-module",
"dist": {
"url": "http://ftp.drupal.org/files/projects/clean_markup-7.x-2.7.tar.gz",
"type": "tar"
}
}
},
{
"type": "package",
"package": {
"name": "drupal/services",
"version": "7.3.10",
"type": "drupal-module",
"dist": {
"url": "http://ftp.drupal.org/files/projects/services-7.x-3.10.tar.gz",
"type": "tar"
}
}
},
{
"type": "package",
"package": {
"name": "drupal/views_datasource",
"version": "7.1.0-alpha1-dev",
"type": "drupal-module",
"source": {
"url": "http://git.drupal.org/project/views_datasource.git",
"type": "git",
"reference": "c15e455cebe36c1a2ef1082da4b0ea7d93db2ed5"
}
}
}
],
"require": {
"davidbarratt/custom-installer": "dev-master",
"drupal-composer/preserve-paths": "0.1.*",
"mynamespace/patches": "*",
"library/backbone": "1.0.0",
"library/underscore": "1.5.2",
"drupal/drupal": "7.34",
"drupal/addressfield": "1.0-rc1",
"drupal/admin_menu": "3.0.0-rc4",
"drupal/auto_entitylabel": "1.2",
"drupal/autologout": "4.3",
"drupal/calendar": "3.5",
"drupal/clean_markup": "2.7",
"drupal/ckeditor": "1.16",
"drupal/content_access": "1.2-beta2",
"drupal/ctools": "1.5",
"drupal/date": "2.8",
"drupal/delete_all": "1.1",
"drupal/devel": "1.5",
"drupal/diff": "3.2",
"drupal/draggableviews": "2.0",
"drupal/ds": "2.7",
"drupal/email": "1.3",
"drupal/features": "2.2",
"drupal/field_group": "1.4",
"drupal/field_permissions": "1.0-beta2",
"drupal/file_entity": "2.0-beta1",
"drupal/flag": "3.5",
"drupal/hide_formats": "1.1",
"drupal/image_url_formatter": "1.4",
"drupal/job_scheduler": "2.0-alpha3",
"drupal/jquery_update": "2.4",
"drupal/libraries": "2.2",
"drupal/link": "1.3",
"drupal/linkit": "3.3",
"drupal/markup": "1.1-beta1",
"drupal/media": "2.0-alpha4",
"drupal/message": "1.9",
"drupal/migrate": "2.5",
"drupal/module_filter": "2.0-alpha2",
"drupal/panelizer": "3.1",
"drupal/panels": "3.4",
"drupal/pathauto": "1.2",
"drupal/phone": "1.0-beta1",
"drupal/publish_button": "1.0",
"drupal/redirect": "1.0-rc1",
"drupal/rules": "2.7",
"drupal/search_autocomplete": "4.0.0",
"drupal/select_or_other": "2.20",
"drupal/session_limit": "2.0.0",
"drupal/services": "3.10",
"drupal/strongarm": "2.0.0",
"drupal/table_element": "1.0-beta1",
"drupal/telephone": "1.0-alpha1",
"drupal/token": "1.5",
"drupal/transliteration": "3.2",
"drupal/view_unpublished": "1.1",
"drupal/views": "3.8",
"drupal/views_bulk_operations": "3.2",
"drush/drush": "^7"
},
"require-dev": {
"drupal/conditional_fields": "3.x-dev#78ecb040828f8b9b38ca6e1c37a69782da8d9f86",
"drupal/entityreference": "1.x-dev#dc4196b4e97e11ff24e762d94864132e12daf7be",
"drupal/password_policy": "1.x-dev#1276fb37c81a1d76911e0fe1b597438030021676",
"drupal/views_datasource": "1.0-alpha1"
},
"config": {
"vendor-dir": "vendor"
},
"extra": {
"custom-installer": {
"drupal-module": "docroot/sites/all/modules/contrib/{$name}/",
"drupal-theme": "docroot/sites/all/themes/contrib/{$name}/",
"drupal-library": "docroot/sites/all/libraries/{$name}/",
"drupal-drush": "docroot/sites/all/drush/{$name}/",
"drupal-profile": "docroot/profiles/{$name}/",
"drupal-core": "docroot/"
},
"preserve-paths": [
"docroot/sites/all/modules/contrib",
"docroot/sites/all/modules/custom",
"docroot/sites/all/modules/features",
"docroot/sites/all/themes/contrib",
"docroot/sites/all/themes/custom",
"docroot/sites/all/libraries",
"docroot/sites/all/drush",
"docroot/sites/default/settings.php",
"docroot/sites/default/files"
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment