mirror of
https://github.com/LukeHagar/stats-action.git
synced 2025-12-06 04:21:26 +00:00
Update release.yaml
This commit is contained in:
15
.github/workflows/release.yaml
vendored
15
.github/workflows/release.yaml
vendored
@@ -40,14 +40,15 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: .
|
path: .
|
||||||
|
|
||||||
- name: Publish or Update Draft Release
|
- uses: stefanzweifel/git-auto-commit-action@v5
|
||||||
|
with:
|
||||||
|
commit_message: "chore(release): ${{ steps.package-info.outputs.version }}"
|
||||||
|
branch: main
|
||||||
|
|
||||||
|
- name: Publish Draft Release if doesn't exist
|
||||||
run: |
|
run: |
|
||||||
if gh release view ${{ steps.package-info.outputs.version }} >/dev/null 2>&1; then
|
if ! gh release view ${{ steps.package-info.outputs.version }} >/dev/null 2>&1; then
|
||||||
gh release edit ${{ steps.package-info.outputs.version }} --title "${{ steps.package-info.outputs.version }}" --generate-notes
|
gh release create --draft ${{ steps.package-info.outputs.version }} --title "${{ steps.package-info.outputs.version }}" --generate-notes
|
||||||
else
|
|
||||||
gh release create --draft ${{ steps.package-info.outputs.version }} --title "${{ steps.package-info.outputs.version }}" --generate-notes
|
|
||||||
fi
|
fi
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- uses: stefanzweifel/git-auto-commit-action@v5
|
|
||||||
|
|||||||
Reference in New Issue
Block a user