diff --git a/.mergify.yml b/.mergify.yml index 67bda426ee..444302ece1 100644 --- a/.mergify.yml +++ b/.mergify.yml @@ -15,52 +15,99 @@ pull_request_rules: git merge upstream/{{base}} git push upstream {{head}} ``` - - name: backport patches to 8.3 branch + - name: notify the backport policy + conditions: + - -label~=^backport + - base=main + actions: + comment: + message: | + This pull request does not have a backport label. Could you fix it @{{author}}? 🙏 + To fixup this pull request, you need to add the backport labels for the needed + branches, such as: + * `backport-/d./d` is the label to automatically backport to the `/d./d` branch. `/d` is the digit + **NOTE**: `backport-skip` has been added to this pull request. + label: + add: + - backport-skip + - name: remove backport-skip label + conditions: + - label~=^backport-\d + - -merged + - -closed + actions: + label: + remove: + - backport-skip + - name: notify the backport has not been merged yet + conditions: + - -merged + - -closed + - author=mergify[bot] + - "#check-success>0" + - schedule=Mon-Mon 06:00-10:00[Europe/Paris] + - "#assignee>=1" + actions: + comment: + message: | + This pull request has not been merged yet. Could you please review and merge it @{{ assignee | join(', @') }}? 🙏 + - name: backport patches to main branch + conditions: + - merged + - label=backport-main + actions: + backport: + assignees: + - "{{ author }}" + labels: + - "backport" + branches: + - "main" + title: "[{{ destination_branch }}](backport #{{ number }}) {{ title }}" + - name: backport patches to 7.15 branch conditions: - merged - base=main - - label=backport-8.3 + - label=backport-7.15 actions: backport: assignees: - "{{ author }}" branches: - - "8.3" + - "7.15" title: "[{{ destination_branch }}] {{ title }} (backport #{{ number }})" labels: - - backport - - name: backport patches to 8.2 branch + - backport + - name: backport patches to 7.16 branch conditions: - merged - base=main - - label=backport-8.2 + - label=backport-7.16 actions: backport: assignees: - "{{ author }}" branches: - - "8.2" + - "7.16" title: "[{{ destination_branch }}] {{ title }} (backport #{{ number }})" labels: - - backport - - name: backport patches to 8.1 branch + - backport + - name: backport patches to 7.17 branch conditions: - merged - - base=main - - label=backport-8.1 + - label=backport-7.17 actions: backport: assignees: - "{{ author }}" branches: - - "8.1" + - "7.17" title: "[{{ destination_branch }}] {{ title }} (backport #{{ number }})" labels: - backport - name: backport patches to 8.0 branch conditions: - merged - - base=main - label=backport-8.0 actions: backport: @@ -71,84 +118,45 @@ pull_request_rules: title: "[{{ destination_branch }}] {{ title }} (backport #{{ number }})" labels: - backport - - name: backport patches to 7.17 branch + - name: backport patches to 8.1 branch conditions: - merged - - base=main - - label=backport-7.17 + - label=backport-8.1 actions: backport: assignees: - "{{ author }}" branches: - - "7.17" + - "8.1" title: "[{{ destination_branch }}] {{ title }} (backport #{{ number }})" labels: - backport - - name: backport patches to 7.16 branch + - name: backport patches to 8.2 branch conditions: - merged - - base=main - - label=backport-7.16 + - label=backport-8.2 actions: backport: assignees: - "{{ author }}" branches: - - "7.16" + - "8.2" title: "[{{ destination_branch }}] {{ title }} (backport #{{ number }})" labels: - backport - - name: backport patches to 7.15 branch + - name: backport patches to 8.3 branch conditions: - merged - - base=main - - label=backport-7.15 + - label=backport-8.3 actions: backport: assignees: - "{{ author }}" branches: - - "7.15" + - "8.3" title: "[{{ destination_branch }}] {{ title }} (backport #{{ number }})" labels: - backport - - name: notify the backport policy - conditions: - - -label~=^backport - - base=main - actions: - comment: - message: | - This pull request does not have a backport label. Could you fix it @{{author}}? 🙏 - To fixup this pull request, you need to add the backport labels for the needed - branches, such as: - * `backport-/d./d` is the label to automatically backport to the `/d./d` branch. `/d` is the digit - **NOTE**: `backport-skip` has been added to this pull request. - label: - add: - - backport-skip - - name: remove backport-skip label - conditions: - - label~=^backport-\d - - -merged - - -closed - actions: - label: - remove: - - backport-skip - - name: notify the backport has not been merged yet - conditions: - - -merged - - -closed - - author=mergify[bot] - - "#check-success>0" - - schedule=Mon-Mon 06:00-10:00[Europe/Paris] - - "#assignee>=1" - actions: - comment: - message: | - This pull request has not been merged yet. Could you please review and merge it @{{ assignee | join(', @') }}? 🙏 - name: backport patches to 8.4 branch conditions: - merged @@ -282,7 +290,6 @@ pull_request_rules: - name: backport patches to 8.14 branch conditions: - merged - - base=main - label=backport-8.14 actions: backport: @@ -296,7 +303,6 @@ pull_request_rules: - name: backport patches to 8.15 branch conditions: - merged - - base=main - label=backport-8.15 actions: backport: