From 8385e5a3df0dff83a3605d543a875f25828a3aac Mon Sep 17 00:00:00 2001 From: galargh Date: Mon, 22 Apr 2024 12:28:54 +0200 Subject: [PATCH] docs: update documentaiton around concurrency --- .github/workflows/test.yml | 8 ++++---- README.md | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index bd55aab..77f4c8f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,15 +12,15 @@ permissions: pull-requests: write concurrency: - group: ${{ github.workflow }}-${{ github.event.workflow_run.pull_requests[0].number || 'unknown' }} + group: ${{ github.workflow }}-${{ github.event.workflow_run.pull_requests[0].number }} cancel-in-progress: true jobs: reusable-workflow: - if: github.event.workflow_run.pull_requests[0] + if: github.event.workflow_run.event == 'pull_reqeust' || github.event.workflow_run.event == 'pull_request_target' uses: ./.github/workflows/comment.yml matrix: - if: github.event.workflow_run.pull_requests[0] + if: github.event.workflow_run.event == 'pull_reqeust' || github.event.workflow_run.event == 'pull_request_target' runs-on: ubuntu-latest outputs: templates: ${{ steps.matrix.outputs.templates }} @@ -39,7 +39,7 @@ jobs: working-directory: templates action: needs: [matrix] - if: github.event.workflow_run.pull_requests[0] + if: github.event.workflow_run.event == 'pull_reqeust' || github.event.workflow_run.event == 'pull_request_target' runs-on: ubuntu-latest strategy: matrix: diff --git a/README.md b/README.md index 8bedab6..12e850e 100644 --- a/README.md +++ b/README.md @@ -32,12 +32,12 @@ permissions: pull-requests: write concurrency: - group: ${{ github.workflow }}-${{ github.event.workflow_run.pull_requests[0].number || 'unknown' }} + group: ${{ github.workflow }}-${{ github.event.workflow_run.pull_requests[0].number }} cancel-in-progress: true jobs: comment: - if: github.event.workflow_run.pull_requests[0] + if: github.event.workflow_run.event == 'pull_reqeust' || github.event.workflow_run.event == 'pull_request_target' uses: ipdxco/sorted-pr-checks/.github/workflows/comment.yml@v1 ```