I am trying to determine if Eclipse on Windows add control-M characters. I have not seen any setting for it in Preferences->Text Editors. If I don't see Control M characters using vi -b on Linux, can I conclude that control-M characters are not present when using eclipse on Windows?
I finally found under Window > Preferences > General > Workspace
the next text file line delimiter preference. Default is the delimiter of the OS you are using Eclipse on, but you can change that.
That means that when you now change a file (coming from Linux) under Windows, and you have not changed the default, the line end convention (of the existing file) will be kept (New text file line delimiter
), but if you create a new file, the convention of your current OS (Windows) will be used.
You can change line delimiters for all existing files for a project by selecting the project and got to File-->Convert Line Delimiters To-->Unix.
This will modify line delimiter for all files under the project. This will solve the issue.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With