about summary refs log tree commit diff
path: root/.github/workflows/check-by-name.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/check-by-name.yml')
-rw-r--r--.github/workflows/check-by-name.yml7
1 files changed, 7 insertions, 0 deletions
diff --git a/.github/workflows/check-by-name.yml b/.github/workflows/check-by-name.yml
index a5070679c9d07..d063d298cc2a6 100644
--- a/.github/workflows/check-by-name.yml
+++ b/.github/workflows/check-by-name.yml
@@ -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