Skip to content

Commit

Permalink
ci: cancel in-progress GH runs for same PR || ref
Browse files Browse the repository at this point in the history
If you're pushing new work it's generally not useful to have CI churning
on the old work. Cancel it and get cooking on the new stuff ASAP.

See github docs for more info:

https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#example-concurrency-groups
  • Loading branch information
cpu committed Nov 6, 2024
1 parent 05ca122 commit 049873f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ on:
schedule:
- cron: '0 21 * * *'

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
build:
name: Build + test
Expand Down

0 comments on commit 049873f

Please sign in to comment.