Publish multi-version documentation site (#1727)

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: bb4b44f0-f505-49c5-9878-76e2b40c7a15
Copilot-Session: 8eac1204-10ae-4319-9333-aee5dd43dcc8
This commit is contained in:
Jeff Handley 2026-07-24 15:55:35 -07:00 • committed by GitHub
commit ae36026695
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

17
scripts/list-versions.mjs Normal file
View file

@ -0,0 +1,17 @@
// Print the versions to build, one per line, as "<slug>\t<ref>".
// Consumed by the multi-version docs workflow to drive its build loop.
//
// Usage: node scripts/list-versions.mjs [--versions <path>]
import { readFile } from "node:fs/promises";
import path from "node:path";
import { manifestPath } from "./manifest-path.mjs";
const arg = process.argv.slice(2);
const i = arg.indexOf("--versions");
const versionsPath = i !== -1 ? path.resolve(arg[i + 1]) : manifestPath;
const manifest = JSON.parse(await readFile(versionsPath, "utf8"));
for (const v of manifest.versions) {
process.stdout.write(`${v.slug}\t${v.ref}\n`);
}