Skip to content

Commit 3185e61

Browse files
authored
cancel past CI runs on push
1 parent 1acbe6c commit 3185e61

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

.github/workflows/ci.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
name: CI
22
env:
33
JULIA_NUM_THREADS: 2
4+
concurrency:
5+
# group by workflow and ref; the last slightly strange component ensures that for pull
6+
# requests, we limit to 1 concurrent job, but for the master branch we don't
7+
group: ${{ github.workflow }}-${{ github.ref }}-${{ (github.ref != 'refs/heads/master' && github.ref != 'refs/heads/main') || github.run_number }}
8+
# Cancel intermediate builds, but only if it is a pull request build.
9+
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
410
on:
511
pull_request:
612
branches:

0 commit comments

Comments
 (0)