Add all recommended triggers to automerge action

Use the full set of triggers from pascalgn/automerge-action docs:
pull_request (labeled, synchronize, opened, etc), pull_request_review,
check_suite, and status events.

Replaces workflow_run trigger which wasn't firing reliably after
the label was added before CI completed.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Ullrich Schäfer 2026-03-23 01:18:54 +01:00
parent 526f721547
commit 1e8e01f8e3
No known key found for this signature in database
GPG key ID: A32FF691A0F752D9

View file

@ -1,11 +1,23 @@
name: Automerge
on:
workflow_run:
workflows: ["CI"]
types: [completed]
pull_request:
types: [labeled]
types:
- labeled
- unlabeled
- synchronize
- opened
- edited
- ready_for_review
- reopened
- unlocked
pull_request_review:
types:
- submitted
check_suite:
types:
- completed
status: {}
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
@ -14,9 +26,6 @@ jobs:
automerge:
name: Automerge PR
runs-on: ubuntu-latest
if: >
github.event_name == 'pull_request' ||
(github.event_name == 'workflow_run' && github.event.workflow_run.conclusion == 'success')
permissions:
contents: write
pull-requests: write