The best way to control Claude Code, Codex and more from any computer or phone
Use GitHub App token when checking out main in release workflow (#1175)
Julius Marminge committed
Mar 17, 2026 at 14:55 UTC
55560f5116c708ad5bbb466039ae4704448711bc
1 file changed
+22
-2
.github/workflows/release.yml
+22
-2
@@ -308,11 +308,31 @@ jobs:
308
needs: [preflight, release]
309
runs-on: ubuntu-24.04
310
steps:
311
+ - id: app_token
312
+ name: Mint release app token
313
+ uses: actions/create-github-app-token@v2
314
+ with:
315
+ app-id: ${{ vars.RELEASE_APP_ID }}
316
+ private-key: ${{ secrets.RELEASE_APP_PRIVATE_KEY }}
317
+ owner: ${{ github.repository_owner }}
318
+
319
- name: Checkout
320
uses: actions/checkout@v6
321
with:
322
ref: main
323
fetch-depth: 0
324
+ token: ${{ steps.app_token.outputs.token }}
325
+ persist-credentials: true
326
+
327
+ - id: app_bot
328
+ name: Resolve GitHub App bot identity
329
+ env:
330
+ GH_TOKEN: ${{ steps.app_token.outputs.token }}
331
+ APP_SLUG: ${{ steps.app_token.outputs.app-slug }}
332
+ run: |
333
+ user_id="$(gh api "/users/${APP_SLUG}[bot]" --jq .id)"
334
+ echo "name=${APP_SLUG}[bot]" >> "$GITHUB_OUTPUT"
335
+ echo "email=${user_id}+${APP_SLUG}[bot]@users.noreply.github.com" >> "$GITHUB_OUTPUT"
336
337
- name: Setup Bun
338
uses: oven-sh/setup-bun@v2
@@ -349,8 +369,8 @@ jobs:
369
exit 0
370
fi
371
352
- git config user.name "github-actions[bot]"
353
- git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
372
+ git config user.name "${{ steps.app_bot.outputs.name }}"
373
+ git config user.email "${{ steps.app_bot.outputs.email }}"
374
375
git add apps/server/package.json apps/desktop/package.json apps/web/package.json packages/contracts/package.json bun.lock
376
git commit -m "chore(release): prepare $RELEASE_TAG"