The default newline symbol in windows is
CRLF, common to Linux and MAC
LF。 I changed the line feed mode of the editor to
LF, I don’t know what potential problems will arise?
Also want to see you how to deal with different systems between the line break problem?
One thing to correct: windows is
In fact, it’s not a big problem. As long as the text editor supports it, it’s OK to use any line end tag — of course, Notepad is not supported. If you open one with Notepad
LFAs the end of the file, there will be no lines.
In addition, like git, under windows, by default, CRLF will be converted to LF when code is submitted and then submitted. When code is updated, lf will also be converted to CRLF to achieve system compatibility.
Of course, there is also a problem that you may need to pay attention to when developing read / write (note not just read) text files.
Thank. But the correct line break for Mac is as follows: the line break before Mac OSX 10.9 is
CR, later versions changed to be compatible with Linux
LF, see:Do line endings differ between Windows and Linux?