Skip to content

Commit

Permalink
try to alert (via webhook) when Mergify is stuck
Browse files Browse the repository at this point in the history
Add a label "waiting too long" if a PR has "merge delay passed"
but is still open without any activity. Somewhat hacky, since
GitHub's API doesn't provide any real hooks for it so I'm guessing
at ways to try to catch it. Can only be tested by merging, since
Mergify won't apply it unless it's on `master`.
  • Loading branch information
geekosaur committed Dec 15, 2024
1 parent 1078916 commit 927f346
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/mergify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,35 @@ pull_request_rules:
- check-success=Bootstrap post job
- 'check-success=docs/readthedocs.org:cabal'

# label when Mergify didn't trigger a merge automatically
- actions:
label:
add:
- waiting too long
name: Waiting out merge delay (used by bot)
conditions:
- base=master
- -draft
- -closed
- -merged
- or:
- label=merge me
- label=squash+merge me
- label=merge+no rebase
- '#approved-reviews-by>=2'
- '#changes-requested-reviews-by=0'
- updated-at<4 days ago
- label=merge delay passed
# oy
# lifted these from branch protection imports
- check-success=fourmolu
- check-success=hlint
- check-success=Meta checks
- check-success=Doctest Cabal
- check-success=Validate post job
- check-success=Bootstrap post job
- 'check-success=docs/readthedocs.org:cabal'

# rebase+merge strategy
- actions:
queue:
Expand Down

0 comments on commit 927f346

Please sign in to comment.