File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -18,21 +18,23 @@ jobs:
1818 - name : Checkout repository
1919 uses : actions/checkout@v4
2020 with :
21- # Use a token with write permissions to push to the branch
22- token : ${{ secrets.GITHUB_TOKEN }}
23- fetch-depth : 0 # Fetch all history for merging
21+ fetch-depth : 0 # Fetch all history for tags
2422
2523 - name : Create release
2624 id : create-release
2725 run : |
2826 # Date in the format YYMMDD
2927 TAG="release/weekly/$(date +%y%m%d)"
28+
29+ # Get previous weekly tag for sparse release notes
30+ PREV_TAG=$(git tag --list 'release/weekly/*' --sort=-creatordate | head -n 1)
31+
3032 # gh release create will automatically create the tag if it doesn't exist
3133 # This triggers the build workflow's tag listener, unlike git tag + git push
3234 # which doesn't trigger workflows when done by Actions tokens
3335 gh release create "$TAG" \
3436 --title "Weekly Release $(date +%y%m%d)" \
3537 --generate-notes \
38+ --notes-start-tag "$PREV_TAG" \
39+ --fail-on-no-commits \
3640 --prerelease
37- env :
38- GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments