MCPcopy Index your code
hub / github.com/claude-code-best/claude-code / getChangedFiles

Function getChangedFiles

src/utils/git.ts:369–382  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

367}
368
369export const getChangedFiles = async (): Promise<string[]> => {
370 const { stdout } = await execFileNoThrow(
371 gitExe(),
372 ['--no-optional-locks', 'status', '--porcelain'],
373 {
374 preserveOutputOnError: false,
375 },
376 )
377 return stdout
378 .trim()
379 .split('\n')
380 .map(line => line.trim().split(' ', 2)[1]?.trim()) // Remove status prefix (e.g., "M ", "A ", "??")
381 .filter(line => typeof line === 'string') // Remove empty entries
382}
383
384export type GitFileStatus = {
385 tracked: string[]

Callers

nothing calls this directly

Calls 1

execFileNoThrowFunction · 0.70

Tested by

no test coverage detected