Skip to content

Commit 0f01f5e

Browse files
committed
ci: Cancel jobs when a new push happens
Jobs should just cancel automatically, it isn't ideal that extensive jobs can continue running for multiple hours after code has been updated. Use a solution from [1] to do this. [1]: https://stackoverflow.com/a/72408109/5380651
1 parent 0a2dc5d commit 0f01f5e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

libm/.github/workflows/main.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@ on:
55
- master
66
pull_request:
77

8+
concurrency:
9+
# Make sure that new pushes cancel running jobs
10+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
11+
cancel-in-progress: true
12+
813
env:
914
CARGO_TERM_COLOR: always
1015
RUSTDOCFLAGS: -Dwarnings

0 commit comments

Comments
 (0)