Skip to content

Commit

Permalink
Fix release workflow: move tag after changelog updated
Browse files Browse the repository at this point in the history
  • Loading branch information
ml-evs committed Feb 5, 2024
1 parent 014524d commit a40aaa1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .github/utils/release_tag_msg.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
TAG_NAME

The full release changelog can be seen in the [online docs](https://matgenix.github.io/qtoolkit/changelog) and in the [repository source file](https://github.com/matgenix/qtoolkit/blob/TAG_NAME/CHANGELOG.md).
6 changes: 6 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,12 @@ jobs:
git config --global user.name "${GIT_USER_NAME}"
git commit CHANGELOG.md -m "Release ${GITHUB_REF#refs/tags/}"
- name: Move tag to new HEAD
run: |
TAG_MSG=.github/utils/release_tag_msg.txt
sed -i "s|TAG_NAME|${GITHUB_REF#refs/tags/}|" "${TAG_MSG}"
git tag -af -F "${TAG_MSG}" ${GITHUB_REF#refs/tags/}
- name: Update '${{ env.PUBLISH_UPDATE_BRANCH }}' with automated changes
uses: CasperWA/push-protected@v2
with:
Expand Down

0 comments on commit a40aaa1

Please sign in to comment.