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

Function commit

__tests__/git-index-currency.test.ts:44–44  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

42 const git = (...args: string[]) => cp.execFileSync('git', args, { cwd: root, encoding: 'utf8', stdio: ['pipe', 'pipe', 'pipe'] });
43 const write = (name: string, symbol: string) => fs.writeFileSync(path.join(root, name), `export function ${symbol}() { return 1; }\n`);
44 const commit = () => { git('add', '-A'); git('commit', '-m', 'change'); return git('rev-parse', 'HEAD').trim(); };
45 const metadata = () => (cg as any).queries;
46 const symbols = (name: string) => cg.searchNodes(name).map(r => r.node.name);
47 const clean = () => expect(cg.getChangedFiles()).toEqual({ added: [], modified: [], removed: [] });

Callers 2

loadUserFunction · 0.50

Calls 1

gitFunction · 0.70

Tested by

no test coverage detected