Skip to content

Commit d3737e3

Browse files
committed
ci: replace release scripts and use current version of semantic-release
1 parent 2832840 commit d3737e3

File tree

3 files changed

+56
-34
lines changed

3 files changed

+56
-34
lines changed

.github/scripts/bump-version

Lines changed: 0 additions & 22 deletions
This file was deleted.

.github/workflows/release.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,11 @@ jobs:
1515
runs-on: ubuntu-latest
1616

1717
steps:
18+
- name: Setup nodejs
19+
uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6
20+
with:
21+
node-version: lts/*
22+
1823
- name: Generate token
1924
id: token
2025
uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf # v2
@@ -34,11 +39,12 @@ jobs:
3439
- name: Install releaser
3540
run: |
3641
npm install -g \
37-
conventional-changelog-conventionalcommits@6.1.0 \
38-
semantic-release@23.1.1 \
42+
semantic-release@25.0.2 \
3943
@semantic-release/changelog \
4044
@semantic-release/git \
41-
@semantic-release/exec
45+
@semantic-release/github \
46+
semantic-release-replace-plugin \
47+
conventional-changelog-conventionalcommits
4248
4349
- name: Run releaser
4450
env:

.releaserc

Lines changed: 47 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -53,28 +53,33 @@
5353
"presetConfig": {
5454
"types": [
5555
{
56-
"type": "feat",
56+
"type": "major",
5757
"section": "Features"
5858
},
5959
{
60-
"type": "major",
60+
"type": "minor",
6161
"section": "Features"
6262
},
6363
{
64-
"type": "minor",
64+
"type": "patch",
65+
"section": "Bugfixes"
66+
},
67+
{
68+
"type": "feat",
6569
"section": "Features"
6670
},
6771
{
6872
"type": "fix",
6973
"section": "Bugfixes"
7074
},
7175
{
72-
"type": "patch",
73-
"section": "Bugfixes"
76+
"type": "deps",
77+
"section": "Dependencies"
7478
},
7579
{
7680
"type": "chore",
77-
"hidden": true
81+
"section": "Miscellaneous",
82+
"hidden": false
7883
},
7984
{
8085
"type": "docs",
@@ -95,9 +100,42 @@
95100
}
96101
],
97102
[
98-
"@semantic-release/exec",
103+
"semantic-release-replace-plugin",
99104
{
100-
"prepareCmd": "./.github/scripts/bump-version ${nextRelease.version}"
105+
"replacements": [
106+
{
107+
"files": [
108+
"deploy/kubernetes/kustomization.yml"
109+
],
110+
"from": "newTag: .*",
111+
"to": "newTag: ${nextRelease.version}",
112+
"results": [
113+
{
114+
"file": "deploy/kubernetes/kustomization.yml",
115+
"hasChanged": true,
116+
"numMatches": 1,
117+
"numReplacements": 1
118+
}
119+
],
120+
"countMatches": true
121+
},
122+
{
123+
"files": [
124+
"pack.toml"
125+
],
126+
"from": "version = \".*\"",
127+
"to": "version = \"${nextRelease.version}\"",
128+
"results": [
129+
{
130+
"file": "pack.toml",
131+
"hasChanged": true,
132+
"numMatches": 1,
133+
"numReplacements": 1
134+
}
135+
],
136+
"countMatches": true
137+
}
138+
]
101139
}
102140
],
103141
[
@@ -115,7 +153,7 @@
115153
[
116154
"@semantic-release/github",
117155
{
118-
"publish": true
156+
"assets": []
119157
}
120158
]
121159
]

0 commit comments

Comments
 (0)