It was brought to my attention that patches containing editor modelines are being rejected until the modelines are removed. Modelines are a great way to instruct the editor to use the proper coding convention on a given file, especially when one works on various projects each with different coding conventions. Is this really such a horrible thing? -- George Staikos KDE Developer http://www.kde.org/ Staikos Computing Services Inc. http://www.staikos.net/
On Thursday 24 August 2006 15:44, George Staikos wrote:
It was brought to my attention that patches containing editor modelines are being rejected until the modelines are removed. Modelines are a great way to instruct the editor to use the proper coding convention on a given file, especially when one works on various projects each with different coding conventions. Is this really such a horrible thing?
Perhaps the right fix for this is not to accept random mode lines from random patches(so to speak), but to in the project guidelines decide for modelines for a 2-3 common editors, and then insert those consistently in all files, and require that new files have them as well. (Of course, I am personally in favour of mode lines since they make the life easier for programmers and helps ensuring the style is respected.) Cheers, Frans
On Thursday 24 August 2006 12:04, Frans Englich wrote:
On Thursday 24 August 2006 15:44, George Staikos wrote:
It was brought to my attention that patches containing editor modelines are being rejected until the modelines are removed. Modelines are a great way to instruct the editor to use the proper coding convention on a given file, especially when one works on various projects each with different coding conventions. Is this really such a horrible thing?
Perhaps the right fix for this is not to accept random mode lines from random patches(so to speak), but to in the project guidelines decide for modelines for a 2-3 common editors, and then insert those consistently in all files, and require that new files have them as well.
(Of course, I am personally in favour of mode lines since they make the life easier for programmers and helps ensuring the style is respected.)
Well in this case I added vim modelines to each file in platform/qt. -- George Staikos KDE Developer http://www.kde.org/ Staikos Computing Services Inc. http://www.staikos.net/
I asked Nikolas to remove the modelines from his already- committed patch to files in platform/qt, but this was more of a request than a mandate. As far as I'm aware there hasn't been a true discussion about the appropriateness of modelines in WebKit -- I was just following our current convention, which is not to have modelines. But it's good that discussion is taking place, as this may make more sense for some platforms than others. -Adam On Aug 24, 2006, at 8:44 AM, George Staikos wrote:
It was brought to my attention that patches containing editor modelines are being rejected until the modelines are removed. Modelines are a great way to instruct the editor to use the proper coding convention on a given file, especially when one works on various projects each with different coding conventions. Is this really such a horrible thing?
-- George Staikos KDE Developer http://www.kde.org/ Staikos Computing Services Inc. http://www.staikos.net/ _______________________________________________ webkit-dev mailing list webkit-dev@opendarwin.org http://www.opendarwin.org/mailman/listinfo/webkit-dev
On Aug 24, 2006, at 8:44 AM, George Staikos wrote:
It was brought to my attention that patches containing editor modelines are being rejected until the modelines are removed. Modelines are a great way to instruct the editor to use the proper coding convention on a given file, especially when one works on various projects each with different coding conventions. Is this really such a horrible thing?
I put this at the top of all C++ files and headers: // -*- mode: c++; c-basic-offset: 4 -*- I think if we want multiple modelines we should agree on which ones and use them consistently. Cheers, Maciej
On Thursday 24 August 2006 13:26, Maciej Stachowiak wrote:
On Aug 24, 2006, at 8:44 AM, George Staikos wrote:
It was brought to my attention that patches containing editor modelines are being rejected until the modelines are removed. Modelines are a great way to instruct the editor to use the proper coding convention on a given file, especially when one works on various projects each with different coding conventions. Is this really such a horrible thing?
I put this at the top of all C++ files and headers:
// -*- mode: c++; c-basic-offset: 4 -*-
I think if we want multiple modelines we should agree on which ones and use them consistently.
I think vim and emacs are the two most common. I would really like to see vim modelines in at least the Qt/KDE related files, but preferably all of them. -- George Staikos KDE Developer http://www.kde.org/ Staikos Computing Services Inc. http://www.staikos.net/
Am Donnerstag, 24. August 2006 19:26 schrieb Maciej Stachowiak:
On Aug 24, 2006, at 8:44 AM, George Staikos wrote:
It was brought to my attention that patches containing editor modelines are being rejected until the modelines are removed. Modelines are a great way to instruct the editor to use the proper coding convention on a given file, especially when one works on various projects each with different coding conventions. Is this really such a horrible thing?
I put this at the top of all C++ files and headers:
// -*- mode: c++; c-basic-offset: 4 -*-
I think if we want multiple modelines we should agree on which ones and use them consistently.
How about committing proper .kateconfig, .emacs-dirvars, .viwhatever configuration files at the project root instead? mfg Leo
On Aug 24, 2006, at 11:55 AM, Leo Savernik wrote:
Am Donnerstag, 24. August 2006 19:26 schrieb Maciej Stachowiak:
On Aug 24, 2006, at 8:44 AM, George Staikos wrote:
It was brought to my attention that patches containing editor modelines are being rejected until the modelines are removed. Modelines are a great way to instruct the editor to use the proper coding convention on a given file, especially when one works on various projects each with different coding conventions. Is this really such a horrible thing?
I put this at the top of all C++ files and headers:
// -*- mode: c++; c-basic-offset: 4 -*-
I think if we want multiple modelines we should agree on which ones and use them consistently.
How about committing proper .kateconfig, .emacs-dirvars, .viwhatever configuration files at the project root instead?
That sounds like a better solution if it works. One tricky aspect: my modeline tells emacs to treat a header as C++, but we also have non-C+ + headers; I'm not sure if treating as C++ for indendation purposes would hurt or not. Cheers, Maciej
participants (5)
-
Adam Roben
-
Frans Englich
-
George Staikos
-
Leo Savernik
-
Maciej Stachowiak