diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 98b121c7bbb8a5c968526c0d39802379a3b60c13..ff6de6eec1f746b9c9e251dc4733a4ee0db64bda 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,5 +1,7 @@ +stages: + - deploy + Deploy: + stage: deploy script: - - "apb deploy" - only: - - some-branch + - curl -XPOST -H'content-type:application/json' "https://packagist.org/api/update-package?username=${PACKAGIST_USERNAME}&apiToken=${PACKAGIST_API_TOKEN}" -d'{"repository":{"url":"'${CI_PROJECT_URL}'"}}' diff --git a/README.md b/README.md index 5131447c28844d638a450862416ed80065b7e8a0..59fdb7ad5f2bc890ec6d21e77a802e88ebd604f0 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,36 @@ # Usage +## Create new project for local development + ``` composer create-project lakedrops/d8-project DIRNAME --stability dev --no-interaction ``` +This will build the full structure and create a git repository which you can then use during the full live-cycle of that project. + +## Deploy project to upstream stages + +For initial deployment, follow this: + +``` +mkdir /PATH/TO/ROOT +cd /PATH/TO/ROOT +git clone YOUR-GIT-REPOSITORY . +composer install +``` + +For later update: + +``` +cd /PATH/TO/ROOT +git pull +composer update +``` + +## Adding new and updating existing components + +Edit the composer.json file accoring to your requirements and then run `composer update`. + # Links [Using Composer to install Drupal packages through Drupal.org](https://www.drupal.org/node/2718229) diff --git a/composer.json b/composer.json index 1c31afb9611f6df0eea0dd53a3a384ddb09e0aba..ecf825b638191a15d118edab4b2e4ce2610b5e92 100644 --- a/composer.json +++ b/composer.json @@ -2,17 +2,27 @@ "name": "lakedrops/d8-project", "description": "Drupal 8 template for a composer based deployment workflow", "type": "project", + "keywords": ["Drupal", "Development", "Install", "Update"], + "homepage": "https://gitlab.paragon-es.de/lakedrops/d8-project", "license": "GPL-2.0+", "authors": [ { "name": "Jürgen Haas", + "email": "juergen@paragon-es.de", + "homepage": "https://www.paragon-es.de", "role": "Drupal Expert" }, { "name": "Richard Papp", + "email": "richard.papp@boromino.com", + "homepage": "http://www.boromino.com", "role": "Drupal Expert" } ], + "support": { + "issues": "https://gitlab.paragon-es.de/lakedrops/d8-project/issues", + "source": "https://gitlab.paragon-es.de/lakedrops/d8-project/tree/master" + }, "repositories": [ { "type": "composer", @@ -23,7 +33,7 @@ "composer/installers": "^1.0.20", "drupal-composer/drupal-scaffold": "^2.0.1", "cweagans/composer-patches": "~1.0", - "lakedrops/d8-project-scaffold": "^0.1.0", + "lakedrops/d8-project-scaffold": "^0.2.0", "drupal/core": "8.1.7", "drush/drush": "~8.0", "drupal/console": "~0.10", diff --git a/drush/README.md b/drush/README.md deleted file mode 100644 index 8c85c145d6dc6a11be19cd21fd1edb55aaad52c6..0000000000000000000000000000000000000000 --- a/drush/README.md +++ /dev/null @@ -1 +0,0 @@ -This directory contains commands, configuration and site aliases for Drush. See http://packages.drush.org/ for a directory of Drush commands installable via Composer. diff --git a/drush/policy.drush.inc b/drush/policy.drush.inc deleted file mode 100644 index 6a1242e5de1aa160a1ea2939d1e5efd359b90722..0000000000000000000000000000000000000000 --- a/drush/policy.drush.inc +++ /dev/null @@ -1,39 +0,0 @@ -<?php - -/* - * Customize this file as desired. See https://github.com/drush-ops/drush/blob/8.x/examples/policy.drush.inc for documentation. - */ - -/** - * Implements drush_hook_COMMAND_validate(). - * - * Encourage folks to use `composer` instead of Drush pm commands - */ -function drush_policy_pm_updatecode_validate() { - return _deny_message(); -} - -function drush_policy_pm_update_validate() { - return _deny_message(); -} - -function drush_policy_pm_download_validate() { - return _deny_message(); -} - -function _deny_message() { - if (!drush_get_option('pm-force')) { - $msg = 'This codebase is assembled with Composer instead of Drush. Use `composer update` and `composer require` instead of `drush pm-updatecode` and `drush pm-download`. You may override this error by using the --pm-force option.'; - return drush_set_error('POLICY_PM_DENY', dt($msg)); - } -} - -/** - * Implements hook_drush_help_alter(). - */ -function policy_drush_help_alter(&$command) { - if (in_array($command['command'], array('pm-updatecode', 'pm-update', 'pm-download'))) { - $command['options']['pm-force'] = 'Override site policy and allow Drush codebase management (pm-* commands)'; - } -} -