You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Recently, I've got a complaint that some of my old scripts for a line by line processing of big files add unexpected new lines. The cause seems to be similar to the one described in this OP.
I suggest two variants of precaution:
Add a small note to the doc + set crlfDelay to Infinity in our main file stream example. This change is milder, but it is also a bit confusing and makes the fs example look like a workaround or even an abuse of terminal API.
Automatically set crlfDelay to Infinity when terminal is false or even completely remove this check from ._normalWrite(). Is there any reason for this option in fs use cases?
Activity
Fishrock123 commentedon Oct 8, 2017
I think 2. seems reasonable?
vsemozhetbyt commentedon Oct 17, 2017
So maybe I shall start with a doc change. If anybody is confident enough to implement the second change, then the doc change can be reverted,
doc: clarify using crlfDelay with fs streams
doc: clarify using crlfDelay with fs streams
doc: clarify using crlfDelay with fs streams
doc: clarify using crlfDelay with fs streams