Re: [JGIT PATCH v2 07/24] Added findWorkTree method to Repository class.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Miklos Vajna <vmiklos@xxxxxxxxxxxxxx> wrote:
> On Fri, May 23, 2008 at 08:12:31PM +0200, Florian Köberle <FloriansKarten@xxxxxx> wrote:
> > Also it is better extenable:
...
> > if (a) {
> > 	something0():
> > +	something1();
> > }
> > 
> > compared too:
> > 
> > -if (a)
> > +if (a) {
> > 	something0();
> > +	something1();
> > + }
> 
> Different programmers have different coding style. A standard is needed,
> otherwise different parts of the code will have different style. It's
> quite normal if a contributor has to code in the project's coding style,
> rather than his own one, I think.
> 
> Also I don't think "but this style is confusing for newbies" is a valid
> argument, newbies should learn to read code, rather than others need to
> write newbie-friendly code. ;-)

Right.

Basically Robin and I have settled on a style not too far from the
one that git.git itself uses, at least where they could pertain to
Java and its semi-C syntax rules.  Part of the reason is because
we (and others in the git community) are just used to this style.

Its shorter vertically, allowing more room for code and comments in
a single screen full.  It also minimizes the number of places where
"\t\t}\n" appear on a line by itself in the context of a patch,
reducing errors from patch hunks applying in the wrong position.

In a little over a month and a half I start a new job.  My new
employer apparently has really strict rules about how code should
be formatted, and everyone in the company has to adhere to them.
No exceptions.  The rules are supposedly quite strange, but the
entire code is at least consistent, and thus easier to follow.
So yea, I get to also go through some strange style thing soon.

When in Rome, do as the Romans do... :-|

-- 
Shawn.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux