LWN.net Logo

Getting the right kind of contributions

Getting the right kind of contributions

Posted May 29, 2008 14:44 UTC (Thu) by dlang (✭ supporter ✭, #313)
In reply to: Getting the right kind of contributions by roc
Parent article: Getting the right kind of contributions

who's preferred layout would everyone agree to use?

Python is trying to do this, but while people who like it tend to really love it, many others
dispise it for the same reasons.


(Log in to post comments)

Getting the right kind of contributions

Posted May 29, 2008 20:03 UTC (Thu) by cpeterso (guest, #305) [Link]

Linux already has an "official" CodyingStyle (including indent configuration) and a checkpatch
script. Perhaps every checkin must be run through indent before acceptance. And to get
everyone up to date with the same baseline indent style, have a flag day where Linus' git tree
gets indented (to fix any currently offending files).

Getting the right kind of contributions

Posted May 29, 2008 20:26 UTC (Thu) by dlang (✭ supporter ✭, #313) [Link]

the initial post was suggesting that someone write a language that enforced the coding style
so that any deviations would result in a compile-time error.

that's a far cry from the kernel coding style document (which by the way, is a guideline, not
a hard requirement. see the flame-wars over checkpatch)

the problem with a flag-day reformat is that it will break everyone's patches that haven't
been merged yet.

the only possible exception to this is Ted suggested doing a flag-day whitespace cleanup, and
modify tools to ignore whitespace changes on the - lines of patches to avoid this
incompatibility.

but other reformatting needs to include a judgement call, not just mechanical formatting

Getting the right kind of contributions

Posted May 29, 2008 21:46 UTC (Thu) by broonie (subscriber, #7078) [Link]

That's actually one of the problems in some areas - patches get knocked back due to violating
CodingStyle but being consistent with the rest of the file they touch. Without going through
and improving the entire file the patch introduces another form of bad practice.

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds