reset(archicrat-ia): canonical docx import and anchors baseline
All checks were successful
SMOKE / smoke (push) Successful in 7s
CI / build-and-anchors (push) Successful in 54s
CI / build-and-anchors (pull_request) Successful in 54s

This commit is contained in:
2026-04-19 16:25:42 +02:00
parent 4976ddcc16
commit c313587b26
10 changed files with 2593 additions and 6494 deletions

View File

@@ -205,12 +205,28 @@ async function main() {
const manifestPath = path.resolve(args.manifest);
const items = await readManifest(manifestPath);
const selected = args.all ? items : items.filter(it => args.only.includes(it.slug));
const selected = args.all
? items
: items.filter((it) => {
const rawSlug = String(it.slug || "").trim();
const rawCollection = String(it.collection || "").trim();
const qualified = `${rawCollection}/${rawSlug}`;
return args.only.includes(rawSlug) || args.only.includes(qualified);
});
if (!args.all && selected.length !== args.only.length) {
const found = new Set(selected.map(s => s.slug));
const missing = args.only.filter(s => !found.has(s));
throw new Error(`Some --only slugs not found in manifest: ${missing.join(", ")}`);
if (!args.all) {
const found = new Set(
selected.flatMap((s) => {
const rawSlug = String(s.slug || "").trim();
const rawCollection = String(s.collection || "").trim();
return [rawSlug, `${rawCollection}/${rawSlug}`];
})
);
const missing = args.only.filter((s) => !found.has(s));
if (missing.length > 0) {
throw new Error(`Some --only slugs not found in manifest: ${missing.join(", ")}`);
}
}
const pandocOk = havePandoc();