From 3476a08c1264fb3357b6407bed63f88162dc8be4 Mon Sep 17 00:00:00 2001 From: Tim Otten Date: Tue, 27 Aug 2019 17:56:40 -0700 Subject: [PATCH] (dev/release#9) distmaker - Report on head for commit civicrm-drupal-8 Overview -------- The general goal is to produce tags for `civicrm-drupal-8` during the release process. The workflow for producing release tags is generally as follows: * Run `distmaker` to prepare a release candidate (a collection of files - e.g. `civicrm-5.18.0-drupal.tar.gz`, `civicrm-5.18.0-joomla.zip`, `civicrm-5.18.0.json`, etc). Note that the JSON file describes the build (i.e. the list of inputs/git-commits and outputs/tarballs). * Use the candidate for `civihydra` testing (i.e. use the tarballs for normal GUI-based installation) * If they work, then run `releaser` - which takes the release candidate files and: * Pushes the tarballs out to CDNs * Pushes the git tags to Github Before ------ * The JSON report describes inputs from the following repos: `civicrm-{backdrop,core,drupal,joomla,packages,wordpress}.git` * To create a complete set of build artifacts, one should have file tree: ``` src/ (civicrm-core.git) WordPress/ (civicrm-wordpress.git) backdrop/ (civicrm-backdrop.git) drupal/ (civicrm-drupal.git) joomla/ (civicrm-joomla.git) packages/ (civicrm-packages.git) ``` After ----- * The JSON report *additionally* reports on `civicrm-drupal-8.git` * To create a complete set of build artifacts, one should also have `drupal-8` in the tree: ``` src/ (civicrm-core.git) WordPress/ (civicrm-wordpress.git) backdrop/ (civicrm-backdrop.git) drupal-8/ (civicrm-drupal-8.git) drupal/ (civicrm-drupal.git) joomla/ (civicrm-joomla.git) packages/ (civicrm-packages.git) ``` Technical Details ----------------- * To produce a report with the D8 commits, one needs have a copy of `drupal-8/` (`civicrm-drupal-8.git`). * However, `distmaker` can still be used without `drupal-8`. (As in the past, so this is still: *if you're only building the Joomla zip file, then you don't need the code for drupal-8 or WordPress*). * There will be a separate patch to: * Checkout `drupal-8` when CI does an automated build * Use the JSON to create tags --- .gitignore | 3 ++- distmaker/distmaker.conf.dist | 1 + distmaker/distmaker.sh | 5 ++++- distmaker/dists/repo-report.sh | 1 + distmaker/utils/repo-report.php | 2 +- 5 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 95f9b09cd8..fd86ffe726 100644 --- a/.gitignore +++ b/.gitignore @@ -25,7 +25,8 @@ tests/phpunit/CiviTest/CiviSeleniumSettings.php tests/phpunit/CiviTest/civicrm.settings.php tools/stats/config.php authors.txt -drupal/ +/drupal/ +/drupal-8/ WordPress joomla packages/ diff --git a/distmaker/distmaker.conf.dist b/distmaker/distmaker.conf.dist index 2d6fd48051..452ea2e50b 100644 --- a/distmaker/distmaker.conf.dist +++ b/distmaker/distmaker.conf.dist @@ -19,6 +19,7 @@ DM_REF_CORE=master DM_REF_BACKDROP=1.x-${DM_REF_CORE} DM_REF_DRUPAL=7.x-${DM_REF_CORE} DM_REF_DRUPAL6=6.x-${DM_REF_CORE} +DM_REF_DRUPAL8=${DM_REF_CORE} DM_REF_JOOMLA=${DM_REF_CORE} DM_REF_WORDPRESS=${DM_REF_CORE} DM_REF_PACKAGES=${DM_REF_CORE} diff --git a/distmaker/distmaker.sh b/distmaker/distmaker.sh index 5471d6ae0d..933be8d2de 100755 --- a/distmaker/distmaker.sh +++ b/distmaker/distmaker.sh @@ -123,7 +123,7 @@ check_conf() echo "Current directory is : $THIS_DIR"; exit 1 else - export DM_SOURCEDIR DM_GENFILESDIR DM_TMPDIR DM_TARGETDIR DM_PHP DM_RSYNC DM_ZIP DM_VERSION DM_REF_CORE DM_REF_DRUPAL DM_REF_DRUPAL6 DM_REF_JOOMLA DM_REF_WORDPRESS DM_REF_PACKAGES + export DM_SOURCEDIR DM_GENFILESDIR DM_TMPDIR DM_TARGETDIR DM_PHP DM_RSYNC DM_ZIP DM_VERSION DM_REF_CORE DM_REF_DRUPAL DM_REF_DRUPAL6 DM_REF_DRUPAL8 DM_REF_JOOMLA DM_REF_WORDPRESS DM_REF_PACKAGES if [ ! -d "$DM_SOURCEDIR" ]; then echo; echo "ERROR! " DM_SOURCEDIR "directory not found!"; echo "(if you get empty directory name, it might mean that one of necessary variables is not set)"; echo; fi @@ -234,6 +234,9 @@ if [ -d "$DM_SOURCEDIR/drupal" ]; then dm_git_checkout "$DM_SOURCEDIR/drupal" "$DM_REF_DRUPAL" GENCODE_CMS=Drupal fi +if [ -d "$DM_SOURCEDIR/drupal-8" ]; then + dm_git_checkout "$DM_SOURCEDIR/drupal-8" "$DM_REF_DRUPAL8" +fi ## Get latest dependencies dm_generate_vendor "$DM_SOURCEDIR" diff --git a/distmaker/dists/repo-report.sh b/distmaker/dists/repo-report.sh index 411ede8e33..32402bb570 100755 --- a/distmaker/dists/repo-report.sh +++ b/distmaker/dists/repo-report.sh @@ -21,6 +21,7 @@ env \ DM_REF_BACKDROP="$DM_REF_BACKDROP" \ DM_REF_DRUPAL6="$DM_REF_DRUPAL6" \ DM_REF_DRUPAL="$DM_REF_DRUPAL" \ + DM_REF_DRUPAL8="$DM_REF_DRUPAL8" \ DM_REF_JOOMLA="$DM_REF_JOOMLA" \ DM_REF_WORDPRESS="$DM_REF_WORDPRESS" \ DM_REF_PACKAGES="$DM_REF_PACKAGES" \ diff --git a/distmaker/utils/repo-report.php b/distmaker/utils/repo-report.php index 27feb512e6..7c3d51279b 100644 --- a/distmaker/utils/repo-report.php +++ b/distmaker/utils/repo-report.php @@ -37,7 +37,7 @@ $data = array( 'civicrm-core' => repo("$DM_SOURCEDIR", getenv('DM_REF_CORE')), 'civicrm-drupal@6.x' => repo("$DM_SOURCEDIR/drupal", getenv('DM_REF_DRUPAL6')), 'civicrm-drupal@7.x' => repo("$DM_SOURCEDIR/drupal", getenv('DM_REF_DRUPAL')), - //'civicrm-drupal@8.x' => repo("$DM_SOURCEDIR/drupal", getenv('DM_REF_DRUPAL8')), + 'civicrm-drupal-8' => repo("$DM_SOURCEDIR/drupal-8", getenv('DM_REF_DRUPAL8')), 'civicrm-joomla' => repo("$DM_SOURCEDIR/joomla", getenv('DM_REF_JOOMLA')), 'civicrm-packages' => repo("$DM_SOURCEDIR/packages", getenv('DM_REF_PACKAGES')), 'civicrm-wordpress' => repo("$DM_SOURCEDIR/WordPress", getenv('DM_REF_WORDPRESS')), -- 2.25.1