Changing line delimiter from Unix to Windows

ri-s-a wrote on Thu Mar 27 12:36:27 CET 2008:
Good morning,

I would like to know, if it is possible to change source formatter behaviour.
I have some problems with editing unix perl source on windows workstation
in Eclipse. After I use source formatter by ctrl-shift-f, everything looks
fine except that line delimiters has changed.

Thank you.

Richard Fojta
jploski wrote on Thu Mar 27 20:31:22 CET 2008:
EPIC uses perltidy to format source code. You can specify additional arguments
to perltidy in EPIC Preferences. Maybe the answer to your question is somewhere
in the perltidy documentation?
secretcode wrote on Tue Jul  1 22:55:43 MEST 2008:
Same issue here. For the record (I don't suppose there is a solution):

I added --preserve-line-endings to Preferences > Perl EPIC > Source Formatter.
The perltidy manpage says "This flag tells perltidy to write its output
files with the same line endings as the input file, if possible. It should
work for dos, unix, and mac line endings. It will only work if perltidy
input comes from a filename (rather than stdin, for example). If perltidy
has trouble determining the input file line ending, it will revert to the
default behavior of using the line ending of the host system."

But after an edit and ctrl-shift-f, the CR+LF line endings are back. It
may be an issue buried in Eclipse.

Note: The above is an archived snapshot of a forum thread. Use the original thread at to post comments.