Skip to content

Commit d4c27e0

Browse files
committed
mergify: fix needs work labels
We have clash with needs work and needs CI labels. If CI fails, we need to be in CI stage. Check for needs: CI label and apply work only if it was CI. Otherwise we would be in the loop.
1 parent e4111ea commit d4c27e0

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

.mergify.yml

+8-5
Original file line numberDiff line numberDiff line change
@@ -47,33 +47,36 @@ pull_request_rules:
4747
- check-failure=cmake-checks
4848
- check-failure=frozen-tools-check
4949
- "label!=mergify skip"
50+
- "label!='needs: work'"
5051
actions:
5152
label:
5253
add: ['needs: work']
5354
remove: ['needs: review', 'needs: CI']
5455

55-
# From needs: review to needs: work - CI failure
56+
# From needs: CI to needs: work - CI failure in jenkins pipeline
5657
- name: "label needs: work when Jenkins CI failed - pr head"
5758
conditions:
58-
# Jenkins CI failing
59+
# Jenkins CI failing, only pr head
5960
- check-failure~=continuous-integration/jenkins/pr-head
6061
- "label!=mergify skip"
62+
- "label=needs: CI"
6163
- -closed
6264
actions:
6365
label:
6466
add: ['needs: work']
65-
remove: ['needs: review','needs: CI']
67+
remove: ['needs: CI']
6668

67-
# From needs: review to needs: work - CI failure
69+
# From needs: CI to needs: work - CI failure
6870
- name: "label needs: work when Jenkins CI failed - any of the pipeline"
6971
conditions:
7072
# Jenkins CI failing - any of the pipeline
7173
- check-failure~=^jenkins-ci
74+
- "label=needs: CI"
7275
- "label!=mergify skip"
7376
actions:
7477
label:
7578
add: ['needs: work']
76-
remove: ['needs: review', 'needs: CI']
79+
remove: ['needs: CI']
7780

7881
# From needs: review or needs: work to needs: CI. One approval means we should be good to start CI
7982
- name: "label needs: CI when at least one reviewers approval"

0 commit comments

Comments
 (0)