Files
mesh-lab/src/repos.ts
T
jschoubben 5d6e8fbe7a Rename mesh-control -> mesh-controller, substrate -> foundation
One name per thing, per the HQ glossary: the module/container/image/binary/repo
becomes mesh-controller, the seat the-controller, and the store+broker pair the
foundation (embedded base bundles, default template and example lock renamed with
their go:embed directives). No behaviour change — a pure vocabulary rename.

Claude-Session: https://claude.ai/code/session_01D6qtiYU3P9jk3pnAXyAFyx
2026-09-16 18:40:40 +02:00

29 lines
1.0 KiB
TypeScript

/**
* Where the repositories this run was pointed at are.
*
* **One place**, because two things need it and they must agree: the rebuild builds these, and the
* receipt claims these. A receipt naming a repository the run did not build is exactly the
* false coverage novox/hq 04-ISSUES/005 is about, and it would arrive by nobody's decision — just
* two derivations drifting.
*
* Derived from the environment the suite is configured by, so a repository this run was not
* pointed at is neither built nor claimed.
*/
import { dirname } from "node:path";
export interface Repositories {
/** Absolute path to the repository root, by name. */
[name: string]: string;
}
export function repositories(env: NodeJS.ProcessEnv = process.env): Repositories {
const found: Repositories = {};
found["mesh-lab"] = process.cwd();
const host = env["MESH_LAB_HOST_BINARY"];
if (host) found["mesh-host"] = dirname(host);
const modules = env["MESH_LAB_MODULES"];
if (modules) found["mesh-controller"] = dirname(dirname(modules));
return found;
}