From 47671ab7aaf7a551ac0d69eadfbe88653131a794 Mon Sep 17 00:00:00 2001 From: "Michael B. Gale" Date: Sat, 28 Feb 2026 16:46:47 +0000 Subject: [PATCH] Track collections --- pr-checks/sync.ts | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/pr-checks/sync.ts b/pr-checks/sync.ts index 77b7ecd69..edd1c165c 100755 --- a/pr-checks/sync.ts +++ b/pr-checks/sync.ts @@ -145,6 +145,15 @@ function main(): void { console.log(`Found ${checkFiles.length} check specification(s).`); + const collections: Record< + string, + Array<{ + specification: Specification; + checkName: string; + inputs: Record; + }> + > = {}; + for (const file of checkFiles) { const checkName = path.basename(file, ".yml"); const checkSpecification = loadYaml(file); @@ -387,6 +396,19 @@ function main(): void { checkJob.env.CODEQL_ACTION_TEST_MODE = true; } + // If this check belongs to a named collection, record it. + if (checkSpecification.collection) { + const collectionName = checkSpecification.collection; + if (!collections[collectionName]) { + collections[collectionName] = []; + } + collections[collectionName].push({ + specification: checkSpecification, + checkName, + inputs: workflowInputs, + }); + } + let extraGroupName = ""; for (const inputName of Object.keys(workflowInputs)) { extraGroupName += "-${{inputs." + inputName + "}}";