Skip to content
Snippets Groups Projects
Commit 1a1a9cac authored by Daniel Dehennin's avatar Daniel Dehennin
Browse files

feat(semantic-release): don't enforce configuration on job rules

* templates/Semantic-release.yaml: remove specific rules to test
  `semantic-release` configuration file existence.
parent d025dce0
No related branches found
No related tags found
3 merge requests!61Publish new release,!60Prepare new release,!57Resolve "semantic-release is not triggered when using commonJS extension for configuration file"
Pipeline #15846 passed
......@@ -42,7 +42,8 @@
# - `.releaserc.yaml`
# - `.releaserc.yml`
#
# - the `.rules-map` rules templates
# - the `.on-stable` rules templates or it must be overriden by the
# extending job to feet your need
#
# - an access token named `GITLAB_TOKEN` with
# - `api`
......@@ -73,7 +74,7 @@
#
.semantic-release:stable:
stage: release
extends: .on-stable-with-semantic-release-config
extends: .on-stable
image: "$SEMANTIC_RELEASE_IMAGE"
variables:
SEMANTIC_RELEASE_IMAGE: 'hub.eole.education/eole/semantic-release-gitlab:latest'
......@@ -109,7 +110,8 @@
# - `.releaserc.yaml`
# - `.releaserc.yml`
#
# - the `.rules-map` rules templates
# - the `.on-testing` rules templates or it must be overriden by the
# extending job to feet your need
#
# - an access token named `GITLAB_TOKEN` with
# - `api`
......@@ -141,7 +143,7 @@
.semantic-release:testing:
extends:
- .semantic-release:stable
- .on-testing-with-semantic-release-config
- .on-testing
#
......@@ -172,7 +174,8 @@
# - `.releaserc.yaml`
# - `.releaserc.yml`
#
# - the `.rules-map` rules templates
# - the `.on-dev` rules templates or it must be overriden by the
# extending job to feet your need
#
# - an access token named `GITLAB_TOKEN` with
# - `api`
......@@ -204,50 +207,5 @@
.semantic-release:dev:
extends:
- .semantic-release:stable
- .on-dev-with-semantic-release-config
.on-stable-with-semantic-release-config:
rules:
- !reference [.rules-map, not-on-schedule]
- !reference [.rules-map, not-on-draft]
- !reference [.rules-map, not-on-semantic-release-commit]
- if: $CI_COMMIT_BRANCH == $STABLE_BRANCH
exists:
- release.config.js
- .releaserc
- .releaserc.yaml
- .releaserc.yml
- .releaserc.json
- .releaserc.js
when: on_success
.on-testing-with-semantic-release-config:
rules:
- !reference [.rules-map, not-on-schedule]
- !reference [.rules-map, not-on-draft]
- !reference [.rules-map, not-on-semantic-release-commit]
- if: $CI_COMMIT_BRANCH == $TESTING_BRANCH
exists:
- release.config.js
- .releaserc
- .releaserc.yaml
- .releaserc.yml
- .releaserc.json
- .releaserc.js
when: on_success
.on-dev-with-semantic-release-config:
rules:
- !reference [.rules-map, not-on-schedule]
- !reference [.rules-map, not-on-draft]
- !reference [.rules-map, not-on-semantic-release-commit]
- if: $CI_COMMIT_BRANCH == $DEV_BRANCH
exists:
- release.config.js
- .releaserc
- .releaserc.yaml
- .releaserc.yml
- .releaserc.json
- .releaserc.js
when: on_success
- .on-dev
...
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment