MCPcopy Index your code
hub / github.com/CodebuffAI/codebuff / constructDiffFromWriteFile

Function constructDiffFromWriteFile

cli/src/utils/implementor-helpers.ts:414–417  ·  view source on GitHub ↗

* Construct a diff view from write_file content.

(content: string)

Source from the content-addressed store, hash-verified

412 * Construct a diff view from write_file content.
413 */
414function constructDiffFromWriteFile(content: string): string {
415 const lines = content.split('\n')
416 return lines.map((line) => `+ ${line}`).join('\n')
417}
418
419/**
420 * Check if a tool is a "create new file" operation.

Callers 1

extractDiffFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected