Skip to content

Commit 2fded6d

Browse files
authored
Merge pull request #4 from AHS12/dev
workflow: update changelog action to create pull requests instead of direct commits
2 parents 9f8f9f9 + 2fcce51 commit 2fded6d

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

.github/workflows/update-changelog.yml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ on:
66

77
permissions:
88
contents: write
9+
pull-requests: write
910

1011
jobs:
1112
update:
@@ -15,18 +16,18 @@ jobs:
1516
steps:
1617
- name: Checkout code
1718
uses: actions/checkout@v4
18-
with:
19-
ref: main
2019

2120
- name: Update Changelog
2221
uses: stefanzweifel/changelog-updater-action@v1
2322
with:
2423
latest-version: ${{ github.event.release.name }}
2524
release-notes: ${{ github.event.release.body }}
2625

27-
- name: Commit updated CHANGELOG
28-
uses: stefanzweifel/git-auto-commit-action@v5
26+
- name: Create Pull Request
27+
uses: peter-evans/create-pull-request@v6
2928
with:
30-
branch: main
31-
commit_message: Update CHANGELOG
32-
file_pattern: CHANGELOG.md
29+
commit-message: "Update CHANGELOG"
30+
branch: changelog/update-${{ github.event.release.tag_name }}
31+
title: "Update CHANGELOG for ${{ github.event.release.tag_name }}"
32+
body: "This PR updates the changelog for ${{ github.event.release.tag_name }}"
33+
base: main

0 commit comments

Comments
 (0)