diff --git a/.github/workflows/cpp-ci-serial-programs-mac-intel.yml b/.github/workflows/cpp-ci-serial-programs-mac-intel.yml index eba6cf90cd..0d21870d54 100644 --- a/.github/workflows/cpp-ci-serial-programs-mac-intel.yml +++ b/.github/workflows/cpp-ci-serial-programs-mac-intel.yml @@ -6,6 +6,12 @@ on: pull_request: types: [opened, synchronize, reopened, ready_for_review] +# When a new event arrives on the same ref (e.g. a new commit pushed to a PR), +# immediately cancel the in-progress workflow started by the older event. +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: build: if: github.event_name != 'pull_request' || github.event.pull_request.draft == false diff --git a/.github/workflows/cpp-ci-serial-programs-mac.yml b/.github/workflows/cpp-ci-serial-programs-mac.yml index e97805b76e..287be02dad 100644 --- a/.github/workflows/cpp-ci-serial-programs-mac.yml +++ b/.github/workflows/cpp-ci-serial-programs-mac.yml @@ -6,6 +6,12 @@ on: pull_request: types: [opened, synchronize, reopened, ready_for_review] +# When a new event arrives on the same ref (e.g. a new commit pushed to a PR), +# immediately cancel the in-progress workflow started by the older event. +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: build: if: github.event_name != 'pull_request' || github.event.pull_request.draft == false diff --git a/.github/workflows/cpp-ci-serial-programs-ubuntu-clang.yml b/.github/workflows/cpp-ci-serial-programs-ubuntu-clang.yml index b05cd243cb..3473ecd5f0 100644 --- a/.github/workflows/cpp-ci-serial-programs-ubuntu-clang.yml +++ b/.github/workflows/cpp-ci-serial-programs-ubuntu-clang.yml @@ -6,6 +6,12 @@ on: pull_request: types: [opened, synchronize, reopened, ready_for_review] +# When a new event arrives on the same ref (e.g. a new commit pushed to a PR), +# immediately cancel the in-progress workflow started by the older event. +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: build: if: github.event_name != 'pull_request' || github.event.pull_request.draft == false diff --git a/.github/workflows/cpp-ci-serial-programs-ubuntu-default.yml b/.github/workflows/cpp-ci-serial-programs-ubuntu-default.yml index d9135a79c6..1d6b3efafb 100644 --- a/.github/workflows/cpp-ci-serial-programs-ubuntu-default.yml +++ b/.github/workflows/cpp-ci-serial-programs-ubuntu-default.yml @@ -6,6 +6,12 @@ on: pull_request: types: [opened, synchronize, reopened, ready_for_review] +# When a new event arrives on the same ref (e.g. a new commit pushed to a PR), +# immediately cancel the in-progress workflow started by the older event. +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: build: if: github.event_name != 'pull_request' || github.event.pull_request.draft == false diff --git a/.github/workflows/cpp-ci-serial-programs-windows-clang.yml b/.github/workflows/cpp-ci-serial-programs-windows-clang.yml index beffaae695..806904ca28 100644 --- a/.github/workflows/cpp-ci-serial-programs-windows-clang.yml +++ b/.github/workflows/cpp-ci-serial-programs-windows-clang.yml @@ -6,6 +6,12 @@ on: pull_request: types: [opened, synchronize, reopened, ready_for_review] +# When a new event arrives on the same ref (e.g. a new commit pushed to a PR), +# immediately cancel the in-progress workflow started by the older event. +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: build: if: github.event_name != 'pull_request' || github.event.pull_request.draft == false diff --git a/.github/workflows/cpp-ci-serial-programs-windows-default.yml b/.github/workflows/cpp-ci-serial-programs-windows-default.yml index 6ab2489835..bb7f9d7c2a 100644 --- a/.github/workflows/cpp-ci-serial-programs-windows-default.yml +++ b/.github/workflows/cpp-ci-serial-programs-windows-default.yml @@ -6,6 +6,12 @@ on: pull_request: types: [opened, synchronize, reopened, ready_for_review] +# When a new event arrives on the same ref (e.g. a new commit pushed to a PR), +# immediately cancel the in-progress workflow started by the older event. +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: build: if: github.event_name != 'pull_request' || github.event.pull_request.draft == false