Developers, please, check your editors settings!

Developers, please, check your editors settings!

by Dmitry Pupinin -
Number of replies: 3
Picture of Core developers Picture of Plugin developers
Big problem is invalid "carriage return" makes some editors.

There are platform's standarts:
*nux - LF
Win - CR LF
Mac - LF CR

but some editors makes "carriage return" with "CR CR LF" sequence!
Many editors, diff and merging tools don't understand this sequence and display empty line between each line.
This is difficult for merging changes, creating patches etc.

This actually for dfwiki, block_attendance and some other contribs.

Average of ratings: -
In reply to Dmitry Pupinin

Re: Developers, please, check your editors settings!

by Eloy Lafuente (stronk7) -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Peer reviewers Picture of Plugin developers Picture of Testers
Yeah, I agree! LF must be the only char!

Just for your info, Macs are so easy wink that they just used CR! Only W32 seems to use more that 1 char for that! big grin

Just joking, of course, ciao smile
In reply to Dmitry Pupinin

Re: Developers, please, check your editors settings!

by Gordon Bateson -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers
Hi Dmitry,
thanks for the head's up smile

I think the HotPot module was one of the culprits. It's newlines seemed to be messed up. Perhaps, it was not the editor that was at fault, but the I had the wrong settings for my CVS client (TortoiseCVS). The conversion from Unix line endings to Windows line endings was not being done properly.

I changed the TortoiseCVS -> preferences -> Advanced:
Sandbox DOS/Unix: Autodetect (default to UNIX)

Then I went through and fixed the line endings in the HotPot files (in the HEAD branch at least) and commited them to the Moodle CVS.

I think that has fixed the problem, but if you notice any further problems with the HotPot module, please let me know.

many thanks
Gordon