MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / run

Function run

packages/hosts/mcp-apps-shell/scripts/subset-fonts.ts:50–57  ·  view source on GitHub ↗
(cmd: string[], cwd: string)

Source from the content-addressed store, hash-verified

48const workDir = path.join(packageRoot, ".fonts-work");
49
50const run = async (cmd: string[], cwd: string): Promise<void> => {
51 const proc = Bun.spawn(cmd, { cwd, stdout: "inherit", stderr: "inherit" });
52 const code = await proc.exited;
53 if (code !== 0) {
54 // oxlint-disable-next-line executor/no-try-catch-or-throw, executor/no-error-constructor -- boundary: a build script reports failure by exiting non-zero
55 throw new Error(`${cmd.join(" ")} exited ${code}`);
56 }
57};
58
59await rm(workDir, { recursive: true, force: true });
60await mkdir(workDir, { recursive: true });

Callers 2

subset-fonts.tsFile · 0.70
subsetFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected