From f5e242ba1b26e6c456c55817aef03f1082692875 Mon Sep 17 00:00:00 2001 From: pbio <10051819+paulbalaji@users.noreply.github.com> Date: Wed, 3 Dec 2025 13:15:24 +0000 Subject: [PATCH] fix(ci): pass GitHub App token to checkout for workflow triggering MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Move token generation before checkout and pass the token to actions/checkout. This ensures git credentials are configured with the GitHub App token, allowing subsequent pushes to trigger CI workflows. Previously, checkout used the default GITHUB_TOKEN which cannot trigger other workflows (GitHub security feature). GitHub App tokens can trigger workflows, but only if used for git authentication. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- .github/workflows/release.yml | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 2a1df5b83..a98402f00 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -18,8 +18,19 @@ jobs: name: Release runs-on: ubuntu-latest steps: + # Generate token first so checkout configures git credentials with it + # This allows subsequent pushes to trigger workflows + - name: Generate GitHub App Token + id: generate-token + uses: actions/create-github-app-token@v2 + with: + app-id: ${{ secrets.HYPER_GONK_APP_ID }} + private-key: ${{ secrets.HYPER_GONK_PRIVATE_KEY }} + - name: Checkout Repo uses: actions/checkout@v4 + with: + token: ${{ steps.generate-token.outputs.token }} - name: Setup Node.js 20 uses: actions/setup-node@v4 @@ -29,13 +40,6 @@ jobs: - name: Install Dependencies run: yarn install --no-immutable - - name: Generate GitHub App Token - id: generate-token - uses: actions/create-github-app-token@v2 - with: - app-id: ${{ secrets.HYPER_GONK_APP_ID }} - private-key: ${{ secrets.HYPER_GONK_PRIVATE_KEY }} - - name: Get GitHub App User ID id: get-user-id run: echo "user-id=$(gh api /users/${{ steps.generate-token.outputs.app-slug }}[bot] --jq .id)" >> "$GITHUB_OUTPUT"