Unverified Commit 75600cde authored by Will Bush's avatar Will Bush
Browse files

workflows: add concurrency group to check-by-name workflow

On event that triggers the workflow for the matching concurrency group, any
previous runs of the workflow in the same group will be cancelled.
parent 80368c5b
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -16,6 +16,13 @@ on:
    # so it shouldn't be a problem
    types: [opened, synchronize, reopened, edited]

# Create a check-by-name concurrency group based on the branch name. if a new
# commit is pushed to the main branch while a previous run is still in progress,
# the previous run will be cancelled and the new one will start.
concurrency:
  group: check-by-name-${{ github.ref }}
  cancel-in-progress: true

permissions:
  # We need this permission to cancel the workflow run if there's a merge conflict
  actions: write