kdelibs coding style

Maks Orlovich mo85 at cornell.edu
Sat Jul 22 23:09:19 BST 2006


On Saturday 22 July 2006 16:56, Thiago Macieira wrote:
> Maks Orlovich wrote:
> >No, it's not. Yes, the proposed policy itself affects only kdelibs. But
> >the /nature/ of the policy affects everyone. This sets a precedent that
> >something that's merely a matter of preference and not technical merit
> > can be legislated as a policy in the project. And in fact, even making
> > kdelibs different in a way that's not technically neccessary (constract
> > with e.g. BC), introduces a small but existing psychological barrier
> > for contributors to jump into kdelibs from other modules.  (And don't
> > bring up kdepim, please. kdepim also has a long-lasting reputation for
> > being hostile to new contributors).
>
> I must have completely misunderstood you. Can you clarify what you meant
> in the paragraph above?
>
> You're saying that, by defining an indentation style, we will be deterring
> potential contributors to kdelibs? That cannot be right.

Yes, I believe it can be a deterring factor. Let me explain: I would say that 
the general laissez-faire nature of KDE as a project, including the lack of 
indentation style played a heavy role in me becoming a KDE contributor. Why? 
First, there is a lot of intimidation factor in joining an open-source 
project, in hacking around. You naturally have to ask yourself whether you're 
good enough, whether you can imagine touching the same code as people like 
David and Waldo. And if the project implicitly says: here, you have an 
account, feel free to hack on whatever, just respect existing contributors' 
work, they're expressing TRUST in the new contributor. And yes, not having an 
indentation style is also expressing trust --- it's the project saying to the 
contributor "we're sure you can make your code nice and readable". Contrast 
this with projects that make you jump through tons of hoops, make one "prove 
one's worth". This is sort of why I make a big distinction between rules and 
suggestions; as the later retain trust in contributors to make the right 
decision.

And moving to kdelibs from hacking on something else is an another transition 
of this sort. The contributor has to be confident, has to feel free to move 
over, despite the intimidation value of the libraries, and the lofty 
reputations of heavy contributors to them. And here, I think, the smaller the 
line is, the more likely the transition. Sure, adding special indentation 
rules to kdelibs isn't adding much, but you never know where someone's 
threshold is. And certainly having one more thing to worry about isn't 
helping things. 

Secondarily, it's about fun. Lots of us aren't paid to hack, after all, and 
creating things, fixing bugs, etc., etc., can be tons of fun. Having your 
work jump through 15 bureaucratic hoops isn't fun. Sending in a patch and 
having as response 50 comments on how they'd rather have it indented often 
isn't fun. (Neither is having someone be a total jerk about your contribution 
because they don't like your indentation style, as I've been told has 
happened a couple years ago). 

-Maks




More information about the kde-core-devel mailing list