ProJucer messes up line endings

Yes, I think LF is the best choice nowadays. Years ago, CRLF was definitely better, so I don’t regret going with it, but things have changed.

We need to tweak the projucer to be more flexible, as we’re starting to use LF a lot more internally too. But converting the whole of JUCE to LF would be quite annoying, as it’d make GIT history and branch merging very awkward, so probably won’t make that decision for a while.

5 Likes

I’ve pushed a couple of changes to the Projucer recently which should improve things. This commit means that the code editor will respect the line endings of the file when saving and loading and won’t just nuke them with CRLF, and also adds a project setting to specify whether the project is using LF or CRLF. New source files that you add via the Projucer will use this line ending and with this commit the auto-generated JUCE project files will also use the specified line ending. In addition, the generated IDE files now use the correct line endings (ie the ones that you get when creating a blank project in that IDE directly).

10 Likes

:slight_smile: