From 20cbb490e55d4d994ab3d48f6bd9e87a8b199287 Mon Sep 17 00:00:00 2001 From: Kevin Yu <31861128+yqlbu@users.noreply.github.com> Date: Sat, 15 Jul 2023 16:51:40 +0800 Subject: [PATCH] ci/fix(pr-build): skip check-run related actions based on condition (#167) * ci/fix(pr-build): skip check-run related actions based on condition * fix: fix syntax * fix: fix syntax * fix: refine condition statement * test: add dummy step to output github context objects * fix: fix syntax * fix: fix syntax * test changes * test changes * fix: fix broken syntax * fix: fix syntax * patch: test with proposed fix --- .github/workflows/pr-build.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pr-build.yml b/.github/workflows/pr-build.yml index a438ce86..6133aa90 100644 --- a/.github/workflows/pr-build.yml +++ b/.github/workflows/pr-build.yml @@ -20,6 +20,7 @@ jobs: echo "$GITHUB_CONTEXT" instantiate-check-runs: + if: startsWith(github.event.pull_request.head.repo.full_name, github.repository_owner) runs-on: ubuntu-latest strategy: matrix: @@ -66,8 +67,8 @@ jobs: path: daed-full-src.zip - name: Report result + if: always() && startsWith(github.event.pull_request.head.repo.full_name, github.repository_owner) uses: daeuniverse/ci-seed-jobs/core/daed/report-check-run@master - if: always() with: app_id: ${{ secrets.GH_APP_ID }} private_key: ${{ secrets.GH_APP_PRIVATE_KEY }} @@ -99,8 +100,8 @@ jobs: path: dist - name: Report result + if: always() && startsWith(github.event.pull_request.head.repo.full_name, github.repository_owner) uses: daeuniverse/ci-seed-jobs/core/daed/report-check-run@master - if: always() with: app_id: ${{ secrets.GH_APP_ID }} private_key: ${{ secrets.GH_APP_PRIVATE_KEY }} @@ -247,15 +248,15 @@ jobs: path: bundled/* - name: Report result + if: always() && startsWith(github.event.pull_request.head.repo.full_name, github.repository_owner) uses: daeuniverse/ci-seed-jobs/core/daed/report-check-run@master - if: always() with: app_id: ${{ secrets.GH_APP_ID }} private_key: ${{ secrets.GH_APP_PRIVATE_KEY }} id: "dae-bot[bot]/build-bundle" conclusion: - if: always() + if: always() && startsWith(github.event.pull_request.head.repo.full_name, github.repository_owner) needs: [build-bundle] runs-on: ubuntu-latest steps: