From 21c6c29ac060b82b54cfa540be8f2d36651b9ea5 Mon Sep 17 00:00:00 2001 From: Tom Boucher Date: Sat, 23 May 2026 00:17:34 -0400 Subject: [PATCH] chore(#140): add concurrency block to 11 PR workflows (#141) Adds `concurrency:` with `cancel-in-progress: true` to the 11 GitHub Actions workflows that previously lacked one. PR-triggered workflows use `github.event.pull_request.number || github.ref` as the group key; schedule- and issue-only workflows use `github.ref`. Co-authored-by: Claude Opus 4.7 --- .github/workflows/auto-branch.yml | 4 ++++ .github/workflows/auto-label-issues.yml | 4 ++++ .github/workflows/branch-cleanup.yml | 4 ++++ .github/workflows/branch-naming.yml | 4 ++++ .github/workflows/changeset-required.yml | 4 ++++ .github/workflows/close-draft-prs.yml | 4 ++++ .github/workflows/docs-required.yml | 4 ++++ .github/workflows/pr-gate.yml | 4 ++++ .github/workflows/pr-template-format.yml | 4 ++++ .github/workflows/require-issue-link.yml | 4 ++++ .github/workflows/stale.yml | 4 ++++ 11 files changed, 44 insertions(+) diff --git a/.github/workflows/auto-branch.yml b/.github/workflows/auto-branch.yml index c5fe2d453..a5c9e2d67 100644 --- a/.github/workflows/auto-branch.yml +++ b/.github/workflows/auto-branch.yml @@ -4,6 +4,10 @@ on: issues: types: [labeled] +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + permissions: contents: write issues: write diff --git a/.github/workflows/auto-label-issues.yml b/.github/workflows/auto-label-issues.yml index 78f167c98..2b19882cb 100644 --- a/.github/workflows/auto-label-issues.yml +++ b/.github/workflows/auto-label-issues.yml @@ -4,6 +4,10 @@ on: issues: types: [opened] +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: add-triage-label: runs-on: ubuntu-latest diff --git a/.github/workflows/branch-cleanup.yml b/.github/workflows/branch-cleanup.yml index 6ca06f2eb..cc19ead90 100644 --- a/.github/workflows/branch-cleanup.yml +++ b/.github/workflows/branch-cleanup.yml @@ -7,6 +7,10 @@ on: - cron: '0 4 * * 0' # Sunday 4am UTC — weekly orphan sweep workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + permissions: contents: write pull-requests: read diff --git a/.github/workflows/branch-naming.yml b/.github/workflows/branch-naming.yml index 2ad65139a..d54bcd281 100644 --- a/.github/workflows/branch-naming.yml +++ b/.github/workflows/branch-naming.yml @@ -4,6 +4,10 @@ on: pull_request: types: [opened, synchronize] +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + permissions: {} jobs: diff --git a/.github/workflows/changeset-required.yml b/.github/workflows/changeset-required.yml index 5baacee97..52c91ff9d 100644 --- a/.github/workflows/changeset-required.yml +++ b/.github/workflows/changeset-required.yml @@ -4,6 +4,10 @@ on: pull_request: types: [opened, synchronize, reopened, labeled, unlabeled] +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + permissions: contents: read pull-requests: read diff --git a/.github/workflows/close-draft-prs.yml b/.github/workflows/close-draft-prs.yml index bfdb336e6..690ae5fbf 100644 --- a/.github/workflows/close-draft-prs.yml +++ b/.github/workflows/close-draft-prs.yml @@ -4,6 +4,10 @@ on: pull_request: types: [opened, reopened, converted_to_draft] +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + permissions: pull-requests: write diff --git a/.github/workflows/docs-required.yml b/.github/workflows/docs-required.yml index 05e88bf3f..8287403c6 100644 --- a/.github/workflows/docs-required.yml +++ b/.github/workflows/docs-required.yml @@ -4,6 +4,10 @@ on: pull_request: types: [opened, synchronize, reopened, labeled, unlabeled] +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + permissions: contents: read pull-requests: read diff --git a/.github/workflows/pr-gate.yml b/.github/workflows/pr-gate.yml index 11b32081d..e1415bb03 100644 --- a/.github/workflows/pr-gate.yml +++ b/.github/workflows/pr-gate.yml @@ -4,6 +4,10 @@ on: pull_request: types: [opened, synchronize] +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + permissions: pull-requests: write issues: write diff --git a/.github/workflows/pr-template-format.yml b/.github/workflows/pr-template-format.yml index 462a4a6f5..92ff5553f 100644 --- a/.github/workflows/pr-template-format.yml +++ b/.github/workflows/pr-template-format.yml @@ -4,6 +4,10 @@ on: pull_request_target: types: [opened, edited, reopened, synchronize, ready_for_review] +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + permissions: contents: read issues: write diff --git a/.github/workflows/require-issue-link.yml b/.github/workflows/require-issue-link.yml index ad7cddda4..60df98014 100644 --- a/.github/workflows/require-issue-link.yml +++ b/.github/workflows/require-issue-link.yml @@ -4,6 +4,10 @@ on: pull_request: types: [opened, edited, reopened, synchronize] +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + permissions: pull-requests: write diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 924ab7175..2d6208229 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -5,6 +5,10 @@ on: - cron: '0 9 * * 1' # Monday 9am UTC workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + permissions: issues: write pull-requests: write