From d851d81219a743f66b77141dad237c2dafe82b83 Mon Sep 17 00:00:00 2001 From: Jeremy Rand Date: Mon, 17 May 2021 12:33:36 +0000 Subject: [PATCH] Cirrus: Fix detection of whether a bump PR is already open --- tools/namecoin-bump-versions.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tools/namecoin-bump-versions.sh b/tools/namecoin-bump-versions.sh index f093967..39a1cb2 100755 --- a/tools/namecoin-bump-versions.sh +++ b/tools/namecoin-bump-versions.sh @@ -171,7 +171,11 @@ if [ "$UPDATE_NEEDED" = 1 ] then echo "An update is required." - (curl -H "Accept: application/vnd.github.v3+json" "https://api.github.com/repos/${CIRRUS_REPO_FULL_NAME}/pulls?state=open&head=NamecoinBot:bump-deps" | grep -i "NamecoinBot:bump-deps") && (echo "A bump PR is already open; exiting."; exit 0) + if curl -H "Accept: application/vnd.github.v3+json" "https://api.github.com/repos/${CIRRUS_REPO_FULL_NAME}/pulls?state=open&head=NamecoinBot:bump-deps" | grep -i "NamecoinBot:bump-deps" + then + echo "A bump PR is already open; exiting." + exit 0 + fi echo "No bump PR is currently open; proceeding."