MCPcopy Create free account
hub / github.com/codeHappyDananx/SpecWave / normalizeEol

Function normalizeEol

electron/main.js:669–673  ·  view source on GitHub ↗
(text, eol)

Source from the content-addressed store, hash-verified

667}
668
669function normalizeEol(text, eol) {
670 const normalized = String(text || '').replace(/\r\n/g, '\n').replace(/\r/g, '\n')
671 if (eol === '\r\n') return normalized.replace(/\n/g, '\r\n')
672 return normalized
673}
674
675function encodeTextBuffer(text, options) {
676 const encoding = options?.encoding || 'utf8'

Callers 1

encodeTextBufferFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected