-
Notifications
You must be signed in to change notification settings - Fork 207
/
.mergify.yml
101 lines (95 loc) · 2.92 KB
/
.mergify.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# Linear queue for the main branch.
shared:
commit_message_template: &commit-message-template |-
{{ title }} (#{{ number }})
{{ body | trim }}
queue_conditions: &queue-conditions
- base=master
- or:
- check-pending=integration-test-result
- check-success=integration-test-result
- label=bypass:integration
- or:
- and: # breakage succeeds like we thought
- check-success=breakage
- -label=proto:expect-breakage
- and: # breakage fails like we thought
- check-failure=breakage
- label=proto:expect-breakage
merge_conditions: &merge-conditions
- base=master
# Rebase PRs with fixup commits are allowed to enter the merge queue but
# should not be allowed to merge if there are leftover fixup commits after rebase
- or:
- label=bypass:linear-history
- check-success=no-fixup-commits
- check-skipped=no-fixup-commits
# Require integration tests before merging only
- or:
- label=bypass:integration
- check-success=integration-test-result
pr_queue_merge_conditions: &pr-queue-merge-conditions
- base=master
- label=automerge:no-update
- or:
- '#commits-behind=0'
- label=bypass:linear-history
pr_queue_rebase_conditions: &pr-queue-rebase-conditions
- base=master
- label=automerge:rebase
- or:
- '#commits-behind>0'
- linear-history
pr_queue_squash_conditions: &pr-queue-squash-conditions
- base=master
- label=automerge:squash
priority_rules:
- name: high_priority
conditions:
- label=priority:high
priority: high
queue_rules:
- name: rebase
commit_message_template: *commit-message-template
queue_conditions: *queue-conditions
merge_conditions: *merge-conditions
merge_method: merge
update_method: rebase
- name: merge
commit_message_template: *commit-message-template
queue_conditions: *queue-conditions
merge_conditions: *merge-conditions
merge_method: merge
- name: squash
commit_message_template: *commit-message-template
queue_conditions: *queue-conditions
merge_conditions: *merge-conditions
merge_method: squash
pull_request_rules:
- name: merge to master
conditions: *pr-queue-merge-conditions
actions:
queue:
name: merge
- name: rebase updates then merge to master
conditions: *pr-queue-rebase-conditions
actions:
queue:
name: rebase
- name: squash to master
conditions: *pr-queue-squash-conditions
actions:
queue:
name: squash
- name: rebase and autosquash
conditions:
- base=master
- label=automerge:rebase
- '#commits-behind=0'
- or:
- -linear-history
- check-failure=no-fixup-commits
- -draft
actions:
rebase:
autosquash: true