From dc32aa7ad8d6e598c8658dfbb83dd9bc4078a900 Mon Sep 17 00:00:00 2001 From: FredApps Date: Tue, 10 Nov 2026 14:51:54 +0100 Subject: [PATCH] ci: give runs outside pull requests their own concurrency group --- .github/workflows/gdi.yml | 5 +++-- .github/workflows/test.yml | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/gdi.yml b/.github/workflows/gdi.yml index 621c21a..4d02173 100644 --- a/.github/workflows/gdi.yml +++ b/.github/workflows/gdi.yml @@ -9,8 +9,9 @@ on: permissions: contents: read concurrency: - group: gdi-${{ github.ref }} - # A newer push to a pull request replaces its older run; runs on main always finish. + # Pull requests share one group per branch, so a newer push cancels the older run. Every other + # run (main, manual) gets a group of its own, so it is neither cancelled nor replaced while queued. + group: gdi-${{ github.event_name == 'pull_request' && github.ref || github.run_id }} cancel-in-progress: ${{ github.event_name == 'pull_request' }} jobs: gdi: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 28961d3..cda2f40 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,8 +12,9 @@ permissions: contents: read concurrency: - group: test-${{ github.ref }} - # A newer push to a pull request replaces its older run; runs on main always finish. + # Pull requests share one group per branch, so a newer push cancels the older run. Every other + # run (main, manual) gets a group of its own, so it is neither cancelled nor replaced while queued. + group: test-${{ github.event_name == 'pull_request' && github.ref || github.run_id }} cancel-in-progress: ${{ github.event_name == 'pull_request' }} env: