From 92c83f657907b4bcf8bf6b7fff99a1c86e885b1c Mon Sep 17 00:00:00 2001 From: Sebastian Delgado Date: Fri, 26 Jan 2018 20:06:10 -0500 Subject: [PATCH] Add conditions to check for core-contributors in merge PR script Signed-off-by: Dmitry Novotochinov --- scripts/merge-pr.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/merge-pr.sh b/scripts/merge-pr.sh index d18e6f6b7c..d69b83a043 100755 --- a/scripts/merge-pr.sh +++ b/scripts/merge-pr.sh @@ -53,7 +53,9 @@ get_pr_info() { if [[ $(echo "$pr_info" | jq -r .state) == closed ]]; then fatal "PR $pr is closed, will not merge" fi - if [[ $(echo "$pr_info" | jq -r .maintainer_can_modify) == true ]]; then + if [[ ($(echo "$pr_info" | jq -r .maintainer_can_modify) == true) ||\ + ($(echo "$pr_info" | jq -r .author_association) == MEMBER) ||\ + ($(echo "$pr_info" | jq -r .author_association) == OWNER)]]; then RW_PR_REPO=1 else warn "PR does not allow 'edits from maintainers', so it will be kept open"