MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / write

Function write

__tests__/sync-lazy-route-value.test.ts:64–74  ·  view source on GitHub ↗
(dir: string, files: Files)

Source from the content-addressed store, hash-verified

62});
63
64function write(dir: string, files: Files): void {
65 for (const [file, text] of Object.entries(files)) {
66 const full = path.join(dir, file);
67 if (text === null) {
68 fs.rmSync(full, { force: true });
69 continue;
70 }
71 fs.mkdirSync(path.dirname(full), { recursive: true });
72 fs.writeFileSync(full, text);
73 }
74}
75
76/** Every node and edge by natural key, edge metadata included, so two indexes of the same files compare directly. */
77function graphOf(graph: CodeGraph): string[] {

Callers 3

freshGraphFunction · 0.70
indexThenSyncWithFunction · 0.70

Calls 1

joinMethod · 0.45

Tested by

no test coverage detected