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

Function sharedFile

__tests__/installer-targets.test.ts:2446–2451  ·  view source on GitHub ↗

A file in the shared folder the links point into, written with `content` when given.

(name: string, content?: string)

Source from the content-addressed store, hash-verified

2444 }
2445 /** A file in the shared folder the links point into, written with `content` when given. */
2446 function sharedFile(name: string, content?: string): string {
2447 const file = path.join(tmpHome, 'dotfiles', name);
2448 fs.mkdirSync(path.dirname(file), { recursive: true });
2449 if (content !== undefined) fs.writeFileSync(file, content);
2450 return file;
2451 }
2452
2453 // Every file each agent's install writes, at both locations: whatever the
2454 // installer does, it never replaces or removes a link.

Callers 1

Calls 1

joinMethod · 0.45

Tested by

no test coverage detected