Skip to content

Commit 06d4f73

Browse files
committed
chore: migrate merge-conflicts workflow to GitHub App (leanprover-community#34747)
This PR migrates the `merge_conflicts.yml` workflow from using a personal access token (`MERGE_CONFLICTS_TOKEN` from `mathlib-merge-conflicts-bot`) to using a GitHub App. 🤖 Prepared with Claude Code
1 parent 58a8e4f commit 06d4f73

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

.github/workflows/merge_conflicts.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,16 @@ jobs:
1010
runs-on: ubuntu-latest
1111
if: github.repository == 'leanprover-community/mathlib4'
1212
steps:
13+
- name: Generate app token
14+
id: app-token
15+
uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf # v2.2.1
16+
with:
17+
app-id: ${{ secrets.MATHLIB_MERGE_CONFLICTS_APP_ID }}
18+
private-key: ${{ secrets.MATHLIB_MERGE_CONFLICTS_PRIVATE_KEY }}
1319
- name: check if prs are dirty
1420
uses: eps1lon/actions-label-merge-conflict@1df065ebe6e3310545d4f4c4e862e43bdca146f0 # v3.0.3
1521
with:
1622
dirtyLabel: "merge-conflict"
1723
commentOnDirty: "This pull request has conflicts, please merge `master` and resolve them."
18-
repoToken: "${{ secrets.MERGE_CONFLICTS_TOKEN }}"
24+
# The create-github-app-token README states that this token is masked and will not be logged accidentally.
25+
repoToken: ${{ steps.app-token.outputs.token }}

0 commit comments

Comments
 (0)