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

docs(getting-started): update `semantic-release` configuration steps

parent 2ba784d8
No related branches found
No related tags found
3 merge requests!61Publish new release,!60Prepare new release,!55Resolve "All semantic-release configuration should be in a single file"
Pipeline #13480 passed
...@@ -332,7 +332,7 @@ you need mostly 4 steps: ...@@ -332,7 +332,7 @@ you need mostly 4 steps:
new-release: {extends: '.semantic-release:stable'} new-release: {extends: '.semantic-release:stable'}
# Create the prereleases versions on `$TESTING_BRANCH` # Create the prereleases versions on `$TESTING_BRANCH`
# update `release.config.js` variable `betaBranch` # update `.releaserc.js` variable `betaBranch`
testing-prerelease: {extends: '.semantic-release:testing'} testing-prerelease: {extends: '.semantic-release:testing'}
# Avoid regression by merging all pre-release fixes to `$DEV_BRANCH` # Avoid regression by merging all pre-release fixes to `$DEV_BRANCH`
...@@ -399,12 +399,10 @@ you need mostly 4 steps: ...@@ -399,12 +399,10 @@ you need mostly 4 steps:
</details> </details>
2. configure [`commitlint`](#validate-commit-messages) with the 2. configure [`commitlint`](#validate-commit-messages) with the
[`.commitlintrc.yaml`](.commitlintrc.yaml) [`.commitlintrc.yaml`](.commitlintrc.yaml)
3. configure [`semantic-release`](#generate-release-with-semantic-version-scheme) 3. configure
1. the general configuration [`semantic-release`](#generate-release-with-semantic-version-scheme)
[`release.config.js`](release.config.js) (note that the in [`.releaserc.js`](.releaserc.js) (note that the `branches` variable must match your `$STABLE_BRANCH`)
`branches` variable must match your `$STABLE_BRANCH`) 4. add a `Dockerfile` in the root directory of your sources
2. the version bump rules in [`release-rules.js`](release-rules.js)
3. add a `Dockerfile` in the root directory of your sources
### Step by step setup ### Step by step setup
...@@ -511,9 +509,7 @@ you need to: ...@@ -511,9 +509,7 @@ you need to:
your `.gitlab-ci.yml` your `.gitlab-ci.yml`
4. define the `new-release` job extending [`.semantic-release:stable`](templates/Semantic-release.yaml#L17-L81) 4. define the `new-release` job extending [`.semantic-release:stable`](templates/Semantic-release.yaml#L17-L81)
5. define the `testing-prerelease` job extending [`.semantic-release:testing`](templates/Semantic-release.yaml#L84-L144) 5. define the `testing-prerelease` job extending [`.semantic-release:testing`](templates/Semantic-release.yaml#L84-L144)
6. configure `semantic-release`: 6. configure `semantic-release` in [`.releaserc.js`](.releaserc.js)
1. [`release.config.js`](release.config.js)
2. [`release-rules.js`](release-rules.js)
```diff ```diff
--- .gitlab-ci.yml.orig --- .gitlab-ci.yml.orig
...@@ -545,7 +541,7 @@ you need to: ...@@ -545,7 +541,7 @@ you need to:
+new-release: {extends: '.semantic-release:stable'} +new-release: {extends: '.semantic-release:stable'}
+ +
+# Create the prereleases versions on `$TESTING_BRANCH` +# Create the prereleases versions on `$TESTING_BRANCH`
+# update `release.config.js` variable `betaBranch` +# update `.releaserc.js` variable `betaBranch`
+testing-prerelease: {extends: '.semantic-release:testing'} +testing-prerelease: {extends: '.semantic-release:testing'}
... ...
``` ```
...@@ -679,7 +675,7 @@ To be used, you need to: ...@@ -679,7 +675,7 @@ To be used, you need to:
new-release: {extends: '.semantic-release:stable'} new-release: {extends: '.semantic-release:stable'}
@@ -68,4 +68,61 @@ @@ -68,4 +68,61 @@
# Create the prereleases versions on `$TESTING_BRANCH` # Create the prereleases versions on `$TESTING_BRANCH`
# update `release.config.js` variable `betaBranch` # update `.releaserc.js` variable `betaBranch`
testing-prerelease: {extends: '.semantic-release:testing} testing-prerelease: {extends: '.semantic-release:testing}
+ +
+## tag contribution branches with a more stable name than `git-${CI_COMMIT_SHORT_SHA}` +## tag contribution branches with a more stable name than `git-${CI_COMMIT_SHORT_SHA}`
...@@ -773,7 +769,7 @@ To do so, you need to: ...@@ -773,7 +769,7 @@ To do so, you need to:
# Create the release versions on `$STABLEE_BRANCH` # Create the release versions on `$STABLEE_BRANCH`
new-release: {extends: '.semantic-release:stable'} new-release: {extends: '.semantic-release:stable'}
@@ -69,6 +70,9 @@ @@ -69,6 +70,9 @@
# update `release.config.js` variable `betaBranch` # update `.releaserc.js` variable `betaBranch`
testing-prerelease: {extends: '.semantic-release:testing} testing-prerelease: {extends: '.semantic-release:testing}
+# Avoid regression by merging all pre-release fixes to `$DEV_BRANCH` +# Avoid regression by merging all pre-release fixes to `$DEV_BRANCH`
......
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