zebra/.github/mergify.yml

67 lines
2.2 KiB
YAML

# Automatic merging of approved PRs for Zebra
#
# This file can be edited and validated using:
# https://dashboard.mergify.com/github/ZcashFoundation/repo/zebra/config-editor
queue_rules:
- name: urgent
# Allow to update/rebase the original pull request if possible to check its mergeability,
# and it does not create a draft PR if not needed
allow_inplace_checks: True
allow_checks_interruption: False
speculative_checks: 1
batch_size: 8
# Wait a short time to embark hotfixes together in a merge train
batch_max_wait_time: "2 minutes"
conditions:
# Mergify automatically applies status check, approval, and conversation rules,
# which are the same as the GitHub main branch protection rules
# https://docs.mergify.com/conditions/#about-branch-protection
- base=main
- name: batched
allow_inplace_checks: True
allow_checks_interruption: True
speculative_checks: 1
batch_size: 20
# Wait for about 10% of the time it takes Rust PRs to run CI (3h)
batch_max_wait_time: "20 minutes"
conditions:
- base=main
pull_request_rules:
- name: move to urgent queue when CI passes with 1 review and not WIP targeting main
conditions:
# This queue handles a PR if:
# - it targets main
# - is not in draft
# - does not include the do-not-merge label
# - is labeled with Critical priority
- base=main
- -draft
- label!=do-not-merge
- 'label~=^P-Critical'
actions:
queue:
name: urgent
method: squash
- name: move to batched queue when CI passes with 1 review and not WIP targeting main
conditions:
# This queue handles a PR if:
# - it targets main
# - is not in draft
# - does not include the do-not-merge label
# - is labeled with any other priority except Critical, or does not have a priority label,
# including automated dependabot PRs.
#
# We don't need to check priority labels here, because the rules are evaluated in order:
# https://docs.mergify.com/configuration/#pull-request-rules
- base=main
- -draft
- label!=do-not-merge
actions:
queue:
name: batched
method: squash