Hi,

It seems the EOL characters keep changing in the .lfm files depending on
the platform last used?

For example:
- If I design a form under Windows, I assume the Form Designer uses CRLF
  as EOL character in the .lfm files.

- Now if I open that exact same file under Linux (note the exact same
  file, not another one checked out by SubVersion). The Form Designer
  converts all the EOL characters from CRLF to LF?

This generates a lot of unnecessary noise!

The reason I ask, is because I sometimes find that due to the Form
Designer, my patches contain a lot of noise. This happens very often
when I use Git or a shared directory between the host OS and a VM OS.
The latter two is things I do very often.

This issue seems minimized when using SubVersion on various platforms,
because SubVersion silently modifies (yuck) all text files on checkout
to match the EOL character used on that platform. Git and a shared
directory NEVER modifies files - what's in the repository is EXACTLY
what you have locally (which I think is the correct way - but that's a
discussion for another day).

What I have also found strange (but better), is that it seems this issue
is only affected by the Form Designer. Standard .pas and .pp files
edited in Lazarus editor (under Linux or Windows) don't seem to generate
that EOL noise when patches are created. Only .lfm files are affected.

Wouldn't it be better if the Form Designer always used a consistent EOL
character - no matter what platform? After all, it should only be the
Form Designer that edits those files.


Tip to Git users:
-----------------
To those Git users also affected by this issue. You can specify the
--ignore-space-at-eol as a parameter to git which will then prevent the
unnecessary diff noise due to the Lazarus Form Designer.


Regards,
  - Graeme -

_______________________________________________________
fpGUI - a cross-platform GUI toolkit using Free Pascal
http://opensoft.homeip.net/fpgui/


--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to