Skip to content

Commit

Permalink
bot: add bot message when pushing on a release branch
Browse files Browse the repository at this point in the history
Normally, only the mergify bot should send out PR to the release
branches. All contributions should generally go in master first then be
backported. Let's warn to avoid merging PR send against a release
branch.

Signed-off-by: Sébastien Han <seb@redhat.com>
  • Loading branch information
leseb committed Nov 25, 2021
1 parent 0dcfefa commit c2d36c3
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .mergify.yml
Expand Up @@ -7,6 +7,14 @@ pull_request_rules:
comment:
message: This pull request has merge conflicts that must be resolved before it can be merged. @{{author}} please rebase it. https://rook.io/docs/rook/latest/development-flow.html#updating-your-fork

- name: ping author on direct push to release branch
conditions:
- base~=^release-
- author!=mergify[bot]
actions:
comment:
message: Hi @{{author}}, this pull request was opened against a release branch, is it expected? Normally patches should go in the master branch first and then be backported to release branches.

# automerge on master only under certain strict conditions
- name: automerge merge master with specific label and approvals with code change
conditions:
Expand Down

0 comments on commit c2d36c3

Please sign in to comment.