MCPcopy Index your code
hub / github.com/getsentry/XcodeBuildMCP / drainLines

Function drainLines

src/utils/xcodebuild-event-parser.ts:448–456  ·  view source on GitHub ↗
(buffer: string, chunk: string)

Source from the content-addressed store, hash-verified

446 }
447
448 function drainLines(buffer: string, chunk: string): string {
449 const combined = buffer + chunk;
450 const lines = combined.split(/\r?\n/u);
451 const remainder = lines.pop() ?? '';
452 for (const line of lines) {
453 processLine(line);
454 }
455 return remainder;
456 }
457
458 return {
459 onStdout(chunk: string): void {

Callers 2

onStdoutFunction · 0.85
onStderrFunction · 0.85

Calls 1

processLineFunction · 0.85

Tested by

no test coverage detected