Skip to content

Commit

Permalink
Fix release workflow
Browse files Browse the repository at this point in the history
- use gh cli because the action is deprecated
- only commit changelog if changes exist
  • Loading branch information
fwilhe2 authored Sep 24, 2023
1 parent 08509d3 commit fb1bc8b
Showing 1 changed file with 10 additions and 12 deletions.
22 changes: 10 additions & 12 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,17 @@ jobs:
component: patch
- run: echo New Version Number ${{ steps.bump.outputs.newVersion }}
- name: Create Release
id: create_release
uses: actions/create-release@v1
run: |
gh release create ${{ steps.bump.outputs.newVersion }} --title "Release ${{ steps.bump.outputs.newVersion }}" --notes-file release-notes-draft.md
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.bump.outputs.newVersion }}
release_name: Release ${{ steps.bump.outputs.newVersion }}
draft: false
prerelease: false
body_path: release-notes-draft.md
- run: |
echo "" > release-notes-draft.md
git config --global user.name 'Florian Wilhelm'
git config --global user.email 'fwilhelm.wgt+github@gmail.com'
git commit -am "Prepare next development iteration"
git push
if [[ `git status --porcelain` ]]; then
git config --global user.name 'Florian Wilhelm'
git config --global user.email 'fwilhelm.wgt+github@gmail.com'
git commit -am "Prepare next development iteration"
git push
else
echo Release has no changelog
fi

0 comments on commit fb1bc8b

Please sign in to comment.