MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / isInsideGitWorkTree

Function isInsideGitWorkTree

apps/kimi-code/src/feedback/codebase/scanner.ts:72–79  ·  view source on GitHub ↗
(root: string)

Source from the content-addressed store, hash-verified

70}
71
72async function isInsideGitWorkTree(root: string): Promise<boolean> {
73 try {
74 const { stdout } = await execFileAsync('git', ['-C', root, 'rev-parse', '--is-inside-work-tree']);
75 return stdout.trim() === 'true';
76 } catch {
77 return false;
78 }
79}
80
81async function scanWithGit(
82 root: string,

Callers 1

scanCodebaseFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected