At the bottom right of the screen in VS Code , click the little button that says LF or CRLF . After changing it to your preference, Voila, the file you're editing now has the correct line breaks.