Re: [PATCH] checkpatch: don't take signature to be part of the commit SHA
From: Ahelenia Ziemiańska
Date: Thu Jun 29 2023 - 08:33:26 EST
On Wed, Jun 28, 2023 at 09:11:00PM -0700, Joe Perches wrote:
> On Wed, 2023-06-28 at 22:35 +0200, Ahelenia Ziemiańska wrote:
> > Grepped through for /log /, /show /, and /git_command/, and this
> > is all I found. Unsure if there's other git executions that need
> > to be fixed, tho.
> Not sure either but perhaps these should be in some
> negative options variable like:
>
> my $git_log_no = "--no-show-signature --no-merges --no-color";
>
> > diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
> []
> > @@ -1164,7 +1164,7 @@ sub seed_camelcase_includes {
> > $camelcase_seeded = 1;
> >
> > if (-e "$gitroot") {
> > - my $git_last_include_commit = `${git_command} log --no-merges --pretty=format:"%h%n" -1 -- include`;
> > + my $git_last_include_commit = `${git_command} log --no-show-signature --no-merges --pretty=format:"%h%n" -1 -- include`;
> my $git_last_include_commit = `${git_command} log ${git_log_no} --pretty=...
git_commit_info doesn't use --no-merges, and so that'd change the
behaviour of "fixes: xxx"/"commit xxx" thusly:
$ git log --no-show-signature --no-color --format="%H %s" -1 e3b2e2c14bcc12da2c463a7179db39139f682573
e3b2e2c14bcc12da2c463a7179db39139f682573 Merge tag 'i2c-for-6.4-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux
$ git log --no-show-signature --no-merges --no-color --format="%H %s" -1 e3b2e2c14bcc12da2c463a7179db39139f682573
afa4bb778e48d79e4a642ed41e3b4e0de7489a6c workqueue: clean up WORK_* constant types, clarify masking
(flattening a referenced merge to its first parent).
Just confirming that's what we want, because I wouldn't think it is?
Attachment:
signature.asc
Description: PGP signature