Skip to content

Commit 8455ab4

Browse files
committed
ci(update-version): use PR_TOKEN for push to protected main
The default GITHUB_TOKEN pushes as github-actions[bot], which is not in the bypass list of `main`'s branch-protection rules, so the push was rejected. Mirror the dependabot-on-demand workflow and check out with secrets.PR_TOKEN so the push is authenticated as a bypass-eligible actor.
1 parent 48a32e7 commit 8455ab4

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

.github/workflows/update-version.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@ jobs:
2222
runs-on: ubuntu-latest
2323
steps:
2424
- uses: actions/checkout@v6
25+
with:
26+
# PAT with bypass rights for the protected `main` branch.
27+
# The default GITHUB_TOKEN cannot push directly to `main`.
28+
token: ${{ secrets.PR_TOKEN }}
2529

2630
- name: Determine version
2731
id: version

0 commit comments

Comments
 (0)