From 316bd87a8a5b8912e9f16475f604fddb12ddaa13 Mon Sep 17 00:00:00 2001 From: Cody Soyland Date: Wed, 14 Oct 2020 17:04:39 -0500 Subject: [PATCH] Fix PR detection logic in CI --- .circleci/config.yml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index bdbc06fbc..2a3fe3158 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -66,7 +66,8 @@ jobs: executor: name: golang steps: - - run: curl https://moleculacorp:$GITHUB_PERSONAL_ACCESS_TOKEN@api.github.com/repos/molecula/pilosa/pulls/$CIRCLE_PR_NUMBER | jq "[.labels[] | .name | startswith(\"changelog\")] | any" -e + - run: '[[ -n $CIRCLE_PULL_REQUEST ]] || circleci step halt || true' # Skip if this is not a pull request + - run: curl https://moleculacorp:$GITHUB_PERSONAL_ACCESS_TOKEN@api.github.com/repos/molecula/pilosa/pulls/$(basename $CIRCLE_PULL_REQUEST) | jq "[.labels[] | .name | startswith(\"changelog\")] | any" -e test-build-arm: executor: name: golang @@ -184,12 +185,9 @@ workflows: requires: - setup - check-changelog-label: + context: molecula requires: - setup - # the following should make this only run on pull requests - filters: - branches: - only: /^pull\/.*$/ - test-build-arm: requires: - setup