Blame Raw
Cohee · b06a6295 · · 39 lines (1.3 KB)
1 contributor
1name: ⚔️ Check Merge Conflicts
2
3on:
4 # So that PRs touching the same files as the push are updated
5 push:
6 # So that the `dirtyLabel` is removed if conflicts are resolved
7 pull_request_target:
8 types: [synchronize]
9
10permissions:
11 contents: read
12 pull-requests: write
13
14jobs:
15 check-merge-conflicts:
16 name: ⚔️ Check Merge Conflicts
17 runs-on: ubuntu-latest
18 if: always()
19
20 steps:
21 - name: Mint App Token
22 id: app
23 # Create a GitHub App token
24 # https://github.com/marketplace/actions/create-github-app-token
25 uses: actions/create-github-app-token@fee1f7d63c2ff003460e3d139729b119787bc349 # v2
26 with:
27 app-id: ${{ vars.ST_BOT_APP_ID }}
28 private-key: ${{ secrets.ST_BOT_PRIVATE_KEY }}
29 owner: ${{ github.repository_owner }}
30
31 - name: Check Merge Conflicts
32 # Label Conflicting Pull Requests
33 # https://github.com/marketplace/actions/label-conflicting-pull-requests
34 uses: eps1lon/actions-label-merge-conflict@1df065ebe6e3310545d4f4c4e862e43bdca146f0 # v3.0.3
35 with:
36 dirtyLabel: '🚫 Merge Conflicts'
37 repoToken: ${{ steps.app.outputs.token }}
38 commentOnDirty: >
39 ⚠️ This PR has conflicts that need to be resolved before it can be merged.