From e988b39f49526ccb8bd19453bd2198bf4156bb7f Mon Sep 17 00:00:00 2001 From: James Kessler Date: Fri, 19 Sep 2025 12:22:01 -0700 Subject: [PATCH] Update workflow to sync and verify release branch (#249) Make sure release branch always points to latest release, and add verification for release branch after tag update. Fixes issue #246 for any users who use `@release/v2` (not recommended) instead of `@v2` (recommended). --- .github/workflows/update-major-version-tag.yml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/.github/workflows/update-major-version-tag.yml b/.github/workflows/update-major-version-tag.yml index ed7cacd2..02129478 100644 --- a/.github/workflows/update-major-version-tag.yml +++ b/.github/workflows/update-major-version-tag.yml @@ -25,8 +25,20 @@ jobs: git tag -f ${{ env.major_version }} ${{ github.event.release.tag_name }} git push origin ${{ env.major_version }} --force + - name: Update release/v* branch to major tag + run: | + git fetch origin + branch_name="release/${{ env.major_version }}" + git branch -f "$branch_name" ${{ env.major_version }} + git push origin "$branch_name" --force + - name: Fetch Updated Tags run: git fetch --tags --force - name: Verify Tag - run: git show ${{ env.major_version }} \ No newline at end of file + run: git show ${{ env.major_version }} + + - name: Verify release/v* branch + run: | + branch_name="release/${{ env.major_version }}" + git show "$branch_name"