Git development
 help / color / mirror / Atom feed
From: Nanako Shiraishi <nanako3@lavabit.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: [PATCH] Mention "local convention" rule in the CodingGuidelines
Date: Mon, 26 Jan 2009 06:15:48 +0900	[thread overview]
Message-ID: <20090126061548.6117@nanako3.lavabit.com> (raw)

The document suggests to imitate the existing code, but didn't
say which existing code it should imitate. This clarifies.

Signed-off-by: しらいしななこ <nanako3@lavabit.com>
---
Quoting Junio C Hamano <gitster@pobox.com>:

> It is always preferable to match the _local_ convention.  I'd expect a new
> script added to git suite to match my preference (the one I showed you in
> my comments to you that is used in git-am, which is what you suggested
> above), but I'd expect a modification to mergetool to match the style
> mergetool already uses.

 Documentation/CodingGuidelines |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/Documentation/CodingGuidelines b/Documentation/CodingGuidelines
index f628c1f..664c6c2 100644
--- a/Documentation/CodingGuidelines
+++ b/Documentation/CodingGuidelines
@@ -21,8 +21,13 @@ code.  For git in general, three rough rules are:
 
 As for more concrete guidelines, just imitate the existing code
 (this is a good guideline, no matter which project you are
-contributing to).  But if you must have a list of rules,
-here they are.
+contributing to). It is always preferable to match the _local_
+convention. A new code added to git suite is expected to match
+the overall style of existing code. A modification to an existing
+code is expected to match the style the surrounding code already
+uses (even if it doesn't match the overall style of existing code).
+
+But if you must have a list of rules, here they are.
 
 For shell scripts specifically (not exhaustive):
 
-- 
Nanako Shiraishi
http://ivory.ap.teacup.com/nanako3/

                 reply	other threads:[~2009-01-25 21:17 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090126061548.6117@nanako3.lavabit.com \
    --to=nanako3@lavabit.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox