feat: add domain core and verification harness
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
import { spawnSync } from "node:child_process";
|
||||
import path from "node:path";
|
||||
import { repositoryRoot } from "./repository-files.mjs";
|
||||
|
||||
const scripts = ["prototype/app.js", "prototype/capture.mjs"];
|
||||
const failures = [];
|
||||
|
||||
for (const script of scripts) {
|
||||
const result = spawnSync(process.execPath, ["--check", path.join(repositoryRoot, script)], {
|
||||
encoding: "utf8",
|
||||
});
|
||||
if (result.status !== 0) {
|
||||
failures.push(`${script}: ${(result.stderr || result.stdout).trim()}`);
|
||||
}
|
||||
}
|
||||
|
||||
if (failures.length > 0) {
|
||||
console.error("Prototype syntax verification failed:");
|
||||
for (const failure of failures) console.error(`- ${failure}`);
|
||||
process.exitCode = 1;
|
||||
} else {
|
||||
console.log(`Prototype syntax verification passed (${scripts.length} files).`);
|
||||
}
|
||||
Reference in New Issue
Block a user