MCPcopy Create free account
hub / github.com/QodeXcli/QodeX / countChangedLines

Function countChangedLines

src/tools/filesystem/multi-file-edit.ts:187–196  ·  view source on GitHub ↗
(a: string, b: string)

Source from the content-addressed store, hash-verified

185 return { content: lines.join('\n') };
186 }
187}
188
189function countChangedLines(a: string, b: string): number {
190 const al = a.split('\n');
191 const bl = b.split('\n');
192 let diff = Math.abs(al.length - bl.length);
193 const min = Math.min(al.length, bl.length);
194 for (let i = 0; i < min; i++) {
195 if (al[i] !== bl[i]) diff++;
196 }
197 return diff;
198}

Callers 1

executeMethod · 0.85

Calls 1

absMethod · 0.80

Tested by

no test coverage detected