Re: [JGIT PATCH v2 07/24] Added findWorkTree method to Repository class.
From: Shawn O. Pearce <hidden>
Date: 2016-06-15 22:44:38
Miklos Vajna [off-list ref] wrote:
On Fri, May 23, 2008 at 08:12:31PM +0200, Florian Köberle [off-list ref] wrote:quoted
Also it is better extenable:
...
quoted
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.