mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
Always convert \r\n and \r sequences to \n on file reading in tool
Fixes https://github.com/meteor/windows-preview/issues/104
This commit is contained in:
@@ -63,7 +63,9 @@ var convertToOSLineEndings = function (fileContents) {
|
||||
};
|
||||
|
||||
var convertToStandardLineEndings = function (fileContents) {
|
||||
return fileContents.replace(new RegExp(os.EOL, "g"), "\n");
|
||||
// Convert all kinds of end-of-line chars to linuxy "\n".
|
||||
return fileContents.replace(new RegExp("\r\n", "g"), "\n")
|
||||
.replace(new RegExp("\r", "g"), "\n");
|
||||
};
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user