MCPcopy
hub / github.com/colbymchenry/codegraph / mkIndexed

Function mkIndexed

__tests__/frontload-hook.test.ts:18–22  ·  view source on GitHub ↗

Make `dir` look indexed (isInitialized needs `.codegraph/codegraph.db`).

(dir: string)

Source from the content-addressed store, hash-verified

16
17/** Make `dir` look indexed (isInitialized needs `.codegraph/codegraph.db`). */
18function mkIndexed(dir: string): string {
19 fs.mkdirSync(path.join(dir, '.codegraph'), { recursive: true });
20 fs.writeFileSync(path.join(dir, '.codegraph', 'codegraph.db'), '');
21 return dir;
22}
23/** A workspace-root manifest so the down-scan gate (looksLikeProjectRoot) passes. */
24function mkWorkspaceRoot(dir: string): string {
25 fs.mkdirSync(dir, { recursive: true });

Callers 1

Calls 1

joinMethod · 0.80

Tested by

no test coverage detected