Skip to content

Commit 13953d3

Browse files
committed
Add changelog generation to release workflow
1 parent 16180c7 commit 13953d3

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

.github/workflows/release.yml

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,24 @@ jobs:
1414
runs-on: ubuntu-latest
1515
outputs:
1616
upload_url: ${{ steps.create_release.outputs.upload_url }}
17-
steps:
17+
steps:
18+
- name: Checkout code
19+
uses: actions/checkout@v4
20+
with:
21+
fetch-depth: 0
22+
token: ${{ secrets.GITHUB_TOKEN }}
23+
- name: Update CHANGELOG.md
24+
uses: orhun/git-cliff-action@v2
25+
with:
26+
args: --latest --prepend CHANGELOG.md
27+
version: ${{ github.ref_name }}
28+
git-commit: true
29+
git-push: true
30+
git-commit-message: "chore: update changelog for ${{ github.ref_name }}"
31+
git-user-name: "github-actions[bot]"
32+
git-user-email: "github-actions[bot]@users.noreply.github.com"
33+
env:
34+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1835
- name: Determine if prerelease
1936
run: |
2037
if [[ "${{ github.ref_name }}" == *"-"* ]]; then

0 commit comments

Comments
 (0)