Skip to content

Local code intelligence for developers and AI agents. Connect code, docs and infrastructure in a persistent graph, with CBM Lens, MCP tools, agent integrations and change-aware test selection.

ci: analyse and score only the newest main commit

Martin Vogel2633334c59a8
diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml
index 2430c6712..621d407fc 100644
--- a/.github/workflows/codeql.yml
+++ b/.github/workflows/codeql.yml
@@ -9,8 +9,12 @@ on:
permissions:
contents: read
+# One analysis per pull request and one per pushed branch. A newer push to main
+# cancels the analysis of an older main commit; only the newest commit's
+# results matter for main, and a merge-heavy day otherwise queues one 40-100
+# minute analysis per merge ahead of every pull request run.
concurrency:
- group: codeql-${{ github.ref }}-${{ github.event.pull_request.number || github.sha }}
+ group: codeql-${{ github.event_name }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
diff --git a/.github/workflows/scorecard.yml b/.github/workflows/scorecard.yml
index c2acbd8ac..fb0a52bbc 100644
--- a/.github/workflows/scorecard.yml
+++ b/.github/workflows/scorecard.yml
@@ -8,6 +8,12 @@ on:
permissions: read-all
+# Only the newest main commit is scored: a newer push (or the weekly run)
+# cancels a pending or running score of an older commit.
+concurrency:
+ group: scorecard-${{ github.ref }}
+ cancel-in-progress: true
+
jobs:
scorecard:
runs-on: ubuntu-latest