Skip to content

Commit eca6d53

Browse files
committed
Enhances release notes workflow with conditions
1 parent 9df9bea commit eca6d53

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

.github/workflows/draft-release-notes.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ on:
1818

1919
jobs:
2020
draft-release-notes:
21+
if: ${{ github.event_name == 'push' }}
22+
2123
permissions:
2224
# write permission is required to create a github release
2325
contents: write
@@ -33,7 +35,7 @@ jobs:
3335
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3436

3537
# Test the Release Drafter config on PRs without modifying the real draft release
36-
draft-release-notes-test:
38+
draft-release-notes-dry-run:
3739
if: ${{ github.event_name == 'pull_request' }}
3840

3941
permissions:
@@ -47,6 +49,6 @@ jobs:
4749
uses: release-drafter/release-drafter@v6
4850
with:
4951
disable-autolabeler: true
50-
dry-run: true
52+
disable-releaser: true # prevents creating/updating the draft
5153
env:
5254
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)