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

Function project

__tests__/dotdot-folder-names.test.ts:40–48  ·  view source on GitHub ↗
(files: Record<string, string>)

Source from the content-addressed store, hash-verified

38});
39
40const project = (files: Record<string, string>): string => {
41 const dir = fs.mkdtempSync(path.join(os.tmpdir(), 'cg-dotdot-'));
42 dirs.push(dir);
43 for (const [rel, content] of Object.entries(files)) {
44 fs.mkdirSync(path.dirname(path.join(dir, rel)), { recursive: true });
45 fs.writeFileSync(path.join(dir, rel), content);
46 }
47 return dir;
48};
49
50const gitCommitAll = (dir: string): void => {
51 execFileSync('git', ['init', '-q'], { cwd: dir });

Callers 2

scoreFunction · 0.70

Calls 2

pushMethod · 0.80
joinMethod · 0.45

Tested by

no test coverage detected