Skip to content

Commit

Permalink
Cancel workflows when they become outdated
Browse files Browse the repository at this point in the history
This change ensures that workflows are canceled when new changes come in which means resources aren't wasted on outdated workflows.

More information: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#concurrency
  • Loading branch information
Windvis committed Feb 3, 2022
1 parent 7eba4a9 commit 7f3424e
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 @@ -13,6 +13,10 @@ on:
pull_request:
branches: [main]

concurrency:
group: ci-${{ github.head_ref || github.ref }}
cancel-in-progress: true

jobs:
preflight:
runs-on: ubuntu-latest
Expand Down

0 comments on commit 7f3424e

Please sign in to comment.