File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 6969 runs-on : ubuntu-latest
7070 permissions :
7171 contents : write
72+ pull-requests : write
7273 env :
7374 VERSION : ${{ needs.validate.outputs.version }}
7475 steps :
@@ -102,17 +103,30 @@ jobs:
102103
103104 - name : Commit & tag
104105 run : |
106+ BRANCH="release/$VERSION"
107+ git checkout -b "$BRANCH"
105108 git add -A
106109 if ! git diff --cached --quiet; then
107110 git commit -m "chore: bump version to $VERSION"
108- git push origin HEAD
109111 fi
110112 if git rev-parse "$VERSION" >/dev/null 2>&1; then
111113 echo "Tag $VERSION already exists, skipping"
112114 else
113115 git tag "$VERSION"
114116 git push origin "$VERSION"
115117 fi
118+ git push origin "$BRANCH"
119+
120+ - name : Create PR to merge version bump back to main
121+ if : ${{ !inputs.dry_run }}
122+ env :
123+ GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
124+ run : |
125+ gh pr create \
126+ --base main \
127+ --head "release/$VERSION" \
128+ --title "chore: bump version to $VERSION" \
129+ --body "Automated version bump from release workflow. Merge after release is complete."
116130
117131 # ---------------------------------------------------------------------------
118132 # 3. Build cross-platform binaries
You can’t perform that action at this time.
0 commit comments