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.
This commit is contained in:
parent
80368c5bef
commit
75600cde6b
1 changed files with 7 additions and 0 deletions
7
.github/workflows/check-by-name.yml
vendored
7
.github/workflows/check-by-name.yml
vendored
|
@ -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
|
||||
|
|
Loading…
Reference in a new issue