Skip to content

Commit 8683d5a

Browse files
authored
👷 ci: Adds automatic Github Release publisher workflow (#97)
1 parent f10e461 commit 8683d5a

File tree

2 files changed

+62
-0
lines changed

2 files changed

+62
-0
lines changed

.github/changelog.json

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
{
2+
"categories": [
3+
{
4+
"title": "## ✨ Features",
5+
"labels": ["enhancement"]
6+
},
7+
{
8+
"title": "## 🐛 Fixes",
9+
"labels": ["bug"]
10+
},
11+
{
12+
"title": "## 🎨 Cleanup",
13+
"labels": ["cleanup"]
14+
},
15+
{
16+
"title": "## 👷 CI/CD",
17+
"labels": ["cicd"]
18+
},
19+
{
20+
"title": "## 📌 Dependencies",
21+
"labels": ["dependencies"]
22+
}
23+
],
24+
"template": "${{CHANGELOG}}\n\n## Contributors:\n${{CONTRIBUTORS}}"
25+
}

.github/workflows/release.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Publish release
2+
3+
on:
4+
push:
5+
tags:
6+
- "v*.*.*"
7+
8+
permissions:
9+
contents: read
10+
11+
jobs:
12+
label:
13+
runs-on: ubuntu-latest
14+
15+
permissions:
16+
contents: read
17+
pull-requests: write
18+
deployments: write
19+
20+
steps:
21+
- uses: step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9.1
22+
with:
23+
egress-policy: audit
24+
25+
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
26+
27+
- uses: mikepenz/release-changelog-builder-action@f3fc77b47b74e78971fffecb2102ae6eac9a44d6 # v5
28+
id: build_changelog
29+
with:
30+
configuration: .github/changelog.json
31+
failOnError: "true"
32+
fetchReviewers: "true"
33+
34+
- uses: softprops/action-gh-release@c062e08bd532815e2082a85e87e3ef29c3e6d191 # v2.0.8
35+
if: startsWith(github.ref, 'refs/tags/')
36+
with:
37+
body: ${{steps.build_changelog.outputs.changelog}}

0 commit comments

Comments
 (0)