All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dirk Gouders <dirk@gouders.net>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 1/1] Documentation/user-manual.txt: example for generating object hashes
Date: Fri, 08 Mar 2024 23:11:56 +0100	[thread overview]
Message-ID: <gho7bo1ihf.fsf@gouders.net> (raw)
In-Reply-To: <xmqqil1wiw5l.fsf@gitster.g> (Junio C. Hamano's message of "Fri, 08 Mar 2024 07:24:38 -0800")

Junio C Hamano <gitster@pobox.com> writes:

> Dirk Gouders <dirk@gouders.net> writes:
>
>> May I ask what you meant by "modulo coding style", e.g. where I should
>> look at to make the code of similar style?
>
> Documentation/CodingGuidelines would be a good start, but
>
>  * A here-doc for a single liner is probably an overkill.  Why not
>
>     echo "Hello, world" >file
>
>    In either way, in our codebase a redirection operator '>' (or
>    '<') has one whitespace before it, and no whitespace after it
>    before the file.
>
>  * printf piped to "cat - file" whose output feeds another pipe
>    looked unusual.  More usual way novices write may be
>
>     { printf ... ; cat file; } | sha1sum
>
> were the two things I noticed.
>
>> I would also add that git-hash-object(1) could be used to verify the
>> result if you think that is OK.
>
> git hash-object can be used to replace that whole thing ;-)
>
>> In addition to a suggestion in another mail, the commit would
>> consist of substantial content you suggested and perhaps, you could tell
>> me how to express this; would a Helped-By be correct?
>
> I think many may prefer to downcase B in By, but if it is
> "substantial", probably.  I do not think I gave much in this
> discussion to become a substantial addition to the original, though.

Thank you for the explanation (some of which I should have found by
myself).

I will send the prepared v2 when I solved my struggling with range-diffs;
that concept is new to me and I have a slow brain -- if one at all.

Dirk

  reply	other threads:[~2024-03-08 22:12 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-29 20:57 [PATCH 0/1] Documentation/user-manual.txt: try to clarify on object hashes Dirk Gouders
2024-02-29 13:05 ` [PATCH 1/1] Documentation/user-manual.txt: example for generating " Dirk Gouders
2024-02-29 21:37   ` Junio C Hamano
2024-02-29 22:35     ` Dirk Gouders
2024-02-29 22:57       ` Junio C Hamano
2024-03-08  6:45     ` Dirk Gouders
2024-03-08 15:24       ` Junio C Hamano
2024-03-08 22:11         ` Dirk Gouders [this message]
2024-03-12 10:41 ` [PATCH v2 0/1] Documentation/user-manual.txt: try to clarify on " Dirk Gouders
2024-03-12 10:41   ` [PATCH v2 1/1] Documentation/user-manual.txt: example for generating " Dirk Gouders

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=gho7bo1ihf.fsf@gouders.net \
    --to=dirk@gouders.net \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.