MCPcopy Create free account
hub / github.com/AnkRoot/Augment-BYOK / loadPatchText

Function loadPatchText

tools/patch/patch-target.js:13–17  ·  view source on GitHub ↗
(filePath, { marker } = {})

Source from the content-addressed store, hash-verified

11}
12
13function loadPatchText(filePath, { marker } = {}) {
14 const target = assertFileExists(filePath);
15 const original = readText(target);
16 return { original, alreadyPatched: !!(marker && original.includes(marker)) };
17}
18
19function savePatchText(filePath, text, { marker } = {}) {
20 const next = marker ? ensureMarker(String(text ?? ""), marker) : String(text ?? "");

Calls 2

assertFileExistsFunction · 0.70
readTextFunction · 0.50

Tested by

no test coverage detected