Skip to content

Commit 62fa7ff

Browse files
authored
ci(release): use app token for release PR updates (#896)
1 parent 29de960 commit 62fa7ff

1 file changed

Lines changed: 15 additions & 2 deletions

File tree

.github/workflows/release-please.yml

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,22 @@ jobs:
1919
release-please:
2020
runs-on: ubuntu-latest
2121
steps:
22+
# Release Please must write release PR branches with an installation token,
23+
# not the default GITHUB_TOKEN. GITHUB_TOKEN-authored pushes do not trigger
24+
# downstream pull_request workflows, so protected release PRs can sit
25+
# blocked waiting for CI/IPR contexts that never start.
26+
- name: Mint App token
27+
id: app-token
28+
uses: actions/create-github-app-token@v3
29+
with:
30+
app-id: ${{ secrets.IPR_APP_ID }}
31+
private-key: ${{ secrets.IPR_APP_PRIVATE_KEY }}
32+
2233
- uses: googleapis/release-please-action@v5
2334
id: release
2435
if: ${{ github.event_name != 'workflow_dispatch' || inputs.publish != true }}
2536
with:
37+
token: ${{ steps.app-token.outputs.token }}
2638
config-file: release-please-config.json
2739
manifest-file: .release-please-manifest.json
2840

@@ -31,6 +43,7 @@ jobs:
3143
uses: actions/checkout@v6
3244
with:
3345
fetch-depth: 0
46+
token: ${{ steps.app-token.outputs.token }}
3447

3548
- name: Normalize release PR pyproject prerelease version
3649
if: ${{ steps.release.outputs.prs_created == 'true' }}
@@ -59,8 +72,8 @@ jobs:
5972
exit 0
6073
fi
6174
62-
git config user.name "github-actions[bot]"
63-
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
75+
git config user.name "aao-ipr-bot[bot]"
76+
git config user.email "aao-ipr-bot[bot]@users.noreply.github.com"
6477
git add pyproject.toml
6578
git commit -m "chore: normalize prerelease version to PEP 440"
6679
git push origin "HEAD:${RELEASE_PR_BRANCH}"

0 commit comments

Comments
 (0)