MCPcopy Index your code
hub / github.com/anomalyco/opencode / text

Function text

packages/session-ui/src/components/session-diff.ts:49–52  ·  view source on GitHub ↗
(diff: ViewDiff, side: "deletions" | "additions")

Source from the content-addressed store, hash-verified

47}
48
49export function text(diff: ViewDiff, side: "deletions" | "additions") {
50 if (side === "deletions") return diff.fileDiff.deletionLines.join("")
51 return diff.fileDiff.additionLines.join("")
52}
53
54function fileDiffFromPatch(file: string, patch: string) {
55 const key = `${file}\0${patch}`

Callers 6

selectionPreviewFunction · 0.90
beforeTextFunction · 0.90
afterTextFunction · 0.90
completePatchContentsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected