Problem/Motivation
Drupal core makes reference to this project's variables and workflows files, as seen here: https://git.drupalcode.org/project/drupal/-/blob/11.x/.gitlab-ci.yml?ref...
For example, core pipelines do fail when run on tags as seen here https://git.drupalcode.org/project/drupal/-/pipelines/78804
The reason is because they have this code in the "composer" job:
# Let composer know what self.version means.
COMPOSER_ROOT_VERSION: "${CI_MERGE_REQUEST_TARGET_BRANCH_NAME}${CI_COMMIT_BRANCH}-dev"
But none of those two variables are available on tags, so the string ends up being "-dev".
We would need to fix this issue outside of core, in the "gitlab_templates" (ie: #3419993: Do not run pipelines on tags for Drupal core), which drives GitLab CI integration for all contrib.
This might not be ideal for core development.
Steps to reproduce
-
Proposed resolution
As agreed with @catch and @longwave in this slack thread (https://drupal.slack.com/archives/C03P8AM3B0Q/p1707206740501299), move the files to core.
Remaining tasks
MR
Issue fork drupal-3420042
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
- 3420042-bring-external-template
changes, plain diff MR !6505
Comments
Comment #3
fjgarlin commentedPending pipelines coming green (https://git.drupalcode.org/issue/drupal-3420042/-/pipelines/90419), this is ready to review.
Comment #4
catchThis is a lot less than I would have expected to need to bring in, so makes sense to consolidate.
Comment #5
longwaveA few questions about the rules.
Comment #6
fjgarlin commentedAll questions/feedback were addressed.
Only one of them wasn't done, and I gave my reasons why I think it's ok to leave it as it is.
Comment #7
longwaveOK, let's leave the variable as-is for now, it can't hurt. The other changes look good and simplify things a bit further, I think this is ready to try for real!
Comment #8
alexpottCommitted and pushed 1366a3ae13 to 11.x and 129230f1c3 to 10.3.x and da6376b9b9 to 10.2.x. Thanks!
Backported to 10.2.x as this is not runtime code.