Skip to content

Commit 04d7c4e

Browse files
Simon Rithjmjohnson
authored andcommitted
ENH: GHA: cancel in progress builds for pull requests
Based on InsightSoftwareConsortium/ITK#5019.
1 parent fba32e8 commit 04d7c4e

3 files changed

Lines changed: 12 additions & 0 deletions

File tree

.github/workflows/build-test-cxx-cuda.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ env:
66
itk-git-tag: "v5.4.0"
77
itk-module-deps: "CudaCommon@cae7c93c2f6d4c5b3cb5f6e5ce4a97686e626bf7"
88

9+
concurrency:
10+
group: '${{ github.workflow }}@${{ github.head_ref || github.run_id }}'
11+
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
12+
913
jobs:
1014
build-test-cxx:
1115
runs-on: ${{ matrix.os }}

.github/workflows/build-test-package-python-cuda.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ env:
88
itk-python-package-org: 'SimonRit'
99
itk-module-deps: "RTKConsortium/ITKCudaCommon@cae7c93c2f6d4c5b3cb5f6e5ce4a97686e626bf7"
1010

11+
concurrency:
12+
group: '${{ github.workflow }}@${{ github.head_ref || github.run_id }}'
13+
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
14+
1115
jobs:
1216
build-linux-cuda-python-packages:
1317
runs-on: self-hosted-linux

.github/workflows/build-test-package.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@ name: Build, test, package
22

33
on: [push,pull_request]
44

5+
concurrency:
6+
group: '${{ github.workflow }}@${{ github.head_ref || github.run_id }}'
7+
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
8+
59
jobs:
610
cxx-build-workflow:
711
uses: InsightSoftwareConsortium/ITKRemoteModuleBuildTestPackageAction/.github/workflows/build-test-cxx.yml@v5.4.0

0 commit comments

Comments
 (0)