From bebb0e3f301bb5dc94fdce5f4e979d13e91c8674 Mon Sep 17 00:00:00 2001 From: Brendan Date: Wed, 16 Sep 2026 15:52:29 +0000 Subject: [PATCH] Use GitHub token for auto-merge --- .github/workflows/auto-merge.yml | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/.github/workflows/auto-merge.yml b/.github/workflows/auto-merge.yml index e41f3ace..924a960a 100644 --- a/.github/workflows/auto-merge.yml +++ b/.github/workflows/auto-merge.yml @@ -10,14 +10,14 @@ on: - synchronize - ready_for_review -permissions: - contents: read - jobs: enable: name: Enable auto-merge runs-on: ubuntu-latest timeout-minutes: 5 + permissions: + contents: write + pull-requests: write steps: # This workflow intentionally does not check out or execute PR code. - name: Check whether the author has write access @@ -40,10 +40,7 @@ jobs: github.event.pull_request.draft == false && steps.author-permission.outputs.can-push == 'true' env: - # A fine-grained PAT or GitHub App token is required here. The built-in - # GITHUB_TOKEN cannot add PRs to a merge queue and can suppress - # downstream push-triggered workflows such as production deployment. - GH_TOKEN: ${{ secrets.AUTOMERGE_TOKEN }} + GH_TOKEN: ${{ github.token }} PR_URL: ${{ github.event.pull_request.html_url }} run: | gh pr merge --auto --merge "$PR_URL"