From: Takashi Iwai <tiwai@suse.de>
To: Johannes Sixt <j6t@kdbg.org>
Cc: Takashi Iwai <tiwai@suse.de>, git@vger.kernel.org
Subject: Re: [PATCH v2] git-gui: Add support of SHA256 repo
Date: Wed, 16 Jul 2025 09:24:00 +0200 [thread overview]
Message-ID: <87ple08upb.wl-tiwai@suse.de> (raw)
In-Reply-To: <c543a644-8e58-4601-8a79-247cd5e124c5@kdbg.org>
On Tue, 15 Jul 2025 21:19:38 +0200,
Johannes Sixt wrote:
>
> Am 15.07.25 um 16:18 schrieb Takashi Iwai:
> > On Mon, 14 Jul 2025 18:28:13 +0200,
> >> BTW, there is a case
> >>
> >> if {[regexp {^[0-9a-f]{1,39}$} $head]}
> >>
> >> around line 3217 in git-gui.sh.
> >
> > Obviously I didn't look for numbers less than 40 :)
> > I'll replace it, too.
> >
> > But I don't understand why it matches up to only 39, not 40 in the
> > code above.
> > It seems trying to get the proper hash id if it's no full length id?
> > If so, the check should be rather like
> > if {![regexp {^[0-9a-f]{40}$} $head]}
> > ?? It makes the conversion a bit simpler.
>
> Obviously, the code wants to turn abbreviated hashes to full hashes.
> That can be skipped if it is already the full length. I haven't analyzed
> why this is needed or desirable.
Maybe it wants only the abbreviated hashes and no other refs?
I'll keep the logic in v3 patch. If any, we can clean up later.
thanks,
Takashi
prev parent reply other threads:[~2025-07-16 7:24 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-03 12:04 [PATCH v2] git-gui: Add support of SHA256 repo Takashi Iwai
2025-07-14 16:28 ` Johannes Sixt
2025-07-15 14:18 ` Takashi Iwai
2025-07-15 19:19 ` Johannes Sixt
2025-07-16 7:24 ` Takashi Iwai [this message]
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=87ple08upb.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=git@vger.kernel.org \
--cc=j6t@kdbg.org \
/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;
as well as URLs for NNTP newsgroup(s).