From caf226372c70a470bf42b52310a03903270afd6e Mon Sep 17 00:00:00 2001 From: NateScarlet Date: Fri, 8 Oct 2021 19:39:37 +0800 Subject: [PATCH] ci: skip coverage report for pr --- .github/workflows/main.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 77c7817..3710693 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -36,6 +36,8 @@ jobs: CC_TEST_REPORTER_ID: ${{secrets.CC_TEST_REPORTER_ID}} run: | coverage xml && coverage report - curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter - chmod +x ./cc-test-reporter - ./cc-test-reporter after-build + if [[ -n "$CC_TEST_REPORTER_ID" ]]; then\ + curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter &&\ + chmod +x ./cc-test-reporter &&\ + ./cc-test-reporter after-build ;\ + fi