From 065abd352f1155f7a02a218b27ab77b953bedd2a Mon Sep 17 00:00:00 2001 From: Maxim Mironenko Date: Sat, 13 Feb 2021 08:56:52 +0700 Subject: [PATCH] mergify rule to close PRs without changes (#280) * mergify rule to close PRs without changes * Update templates/terraform/.github/mergify.yml Co-authored-by: Erik Osterman (CEO @ Cloud Posse) --- templates/terraform/.github/mergify.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/templates/terraform/.github/mergify.yml b/templates/terraform/.github/mergify.yml index b0106567e..ef15545ec 100644 --- a/templates/terraform/.github/mergify.yml +++ b/templates/terraform/.github/mergify.yml @@ -56,3 +56,10 @@ pull_request_rules: changes_requested: true approved: true message: "This Pull Request has been updated, so we're dismissing all reviews." + +- name: "close Pull Requests without files changed" + conditions: + - "#files=0" + actions: + close: + message: "This pull request has been automatically closed by Mergify because there are no longer any changes."