From ff076a5a40ead8c3bd07c1a252d6abc70f461999 Mon Sep 17 00:00:00 2001 From: Michel Roegl-Brunner <73236783+michelroegl-brunner@users.noreply.github.com> Date: Tue, 7 Oct 2025 11:19:43 +0200 Subject: [PATCH] Authenticate gh with PAT before merging PR Updated GitHub Actions workflow to authenticate with a Personal Access Token (PAT) before merging pull requests. --- .github/workflows/publish_release.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish_release.yml b/.github/workflows/publish_release.yml index bb9294f..47a70d5 100644 --- a/.github/workflows/publish_release.yml +++ b/.github/workflows/publish_release.yml @@ -67,11 +67,17 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - name: Merge PR + - name: Authenticate gh with PAT run: | - gh pr merge ${{ steps.pr.outputs.pr_number }} --squash --admin + echo "${{ secrets.MERGE_PAT }}" | gh auth login --with-token + + + - name: Merge PR as PAT user + run: | + gh pr merge "${{ steps.pr.outputs.pr_number }}" --squash --body "Merge VERSION update" --admin env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - name: Wait for PR merge uses: actions/github-script@v7