This repository has been archived by the owner on Sep 3, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.mergify.yml
69 lines (67 loc) · 1.6 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
pull_request_rules:
#######################
# MERGE PRECONDITIONS
#######################
- name: add WIP label when WIP is in title
conditions:
- title~=WIP
actions:
comment:
message: Please remove WIP from the title. We have set the WIP Label for you instead.
label:
add:
- WIP
- name: remove "ready to merge" label when pull is not approved yet
conditions:
- -status-success~=pullapprove
- label~=ready to merge
actions:
comment:
message: The "ready to merge" label can only be set on approved pull request
label:
remove:
- ready to merge
- name: label PRs with conflicts
conditions:
- conflict
actions:
label:
add:
- has conflicts
- name: remove has conflicts label if conflicts got resolved
conditions:
- label~=has conflicts
- -conflict
actions:
label:
remove:
- has conflicts
#######################
# AUTO MERGING
#######################
- name: auto merge when ready to merge label is set
conditions:
- label=ready to merge
actions:
merge:
method: merge
strict: smart
#######################
# CLEANUP AFTER MERGE
#######################
- name: remove ready to merge when merged
conditions:
- merged
- label=ready to merge
actions:
label:
add:
- auto_merged
remove:
- ready to merge
- name: delete merged branches
conditions:
- merged
- label!=WIP
actions:
delete_head_branch: {}