diff mbox series

[v2,2/3] CodingGuidelines: hint why we value clearly written log messages

Message ID 20220126234205.2923388-3-gitster@pobox.com (mailing list archive)
State New, archived
Headers show
Series contributor doc update around log messages | expand

Commit Message

Junio C Hamano Jan. 26, 2022, 11:42 p.m. UTC
Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
 Documentation/CodingGuidelines | 7 +++++++
 1 file changed, 7 insertions(+)

Comments

Eric Sunshine Jan. 27, 2022, 7:31 a.m. UTC | #1
On Thu, Jan 27, 2022 at 1:32 AM Junio C Hamano <gitster@pobox.com> wrote:
> Signed-off-by: Junio C Hamano <gitster@pobox.com>
> ---
> diff --git a/Documentation/CodingGuidelines b/Documentation/CodingGuidelines
> @@ -26,6 +26,13 @@ code.  For Git in general, a few rough rules are:
> + - Log messages to explain your changes are as much important as the

Nit: Dropping "much" makes this sound a bit better grammatically:

"Log messages which explain your changes are as important as the..."

> +   changes themselves.  Clearly written code and in-code comments
> +   explain how the code works and what is assumed from the surrounding
> +   context.  The log messages explain what the changes wanted to
> +   achieve and why the changes were necessary (more on this in the
> +   accompanying SubmittingPatches document).
Junio C Hamano Jan. 27, 2022, 6:35 p.m. UTC | #2
Eric Sunshine <sunshine@sunshineco.com> writes:

> Nit: Dropping "much" makes this sound a bit better grammatically:

Thanks.
diff mbox series

Patch

diff --git a/Documentation/CodingGuidelines b/Documentation/CodingGuidelines
index 0e27b5395d..5f40595f6e 100644
--- a/Documentation/CodingGuidelines
+++ b/Documentation/CodingGuidelines
@@ -26,6 +26,13 @@  code.  For Git in general, a few rough rules are:
    go and fix it up."
    Cf. http://lkml.iu.edu/hypermail/linux/kernel/1001.3/01069.html
 
+ - Log messages to explain your changes are as much important as the
+   changes themselves.  Clearly written code and in-code comments
+   explain how the code works and what is assumed from the surrounding
+   context.  The log messages explain what the changes wanted to
+   achieve and why the changes were necessary (more on this in the
+   accompanying SubmittingPatches document).
+
 Make your code readable and sensible, and don't try to be clever.
 
 As for more concrete guidelines, just imitate the existing code