[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220908090100.155b9b26@canb.auug.org.au>
Date: Thu, 8 Sep 2022 09:01:00 +1000
From: Stephen Rothwell <sfr@...b.auug.org.au>
To: Joe Perches <joe@...ches.com>
Cc: Philippe Schenker <dev@...henker.ch>,
Andy Whitcroft <apw@...onical.com>,
linux-kernel@...r.kernel.org,
Dwaipayan Ray <dwaipayanray1@...il.com>,
Lukas Bulwahn <lukas.bulwahn@...il.com>,
Shawn Guo <shawnguo@...nel.org>,
Philippe Schenker <philippe.schenker@...adex.com>
Subject: Re: [PATCH] checkpatch: add check for fixes: tag
Hi Joe,
On Wed, 07 Sep 2022 08:18:31 -0700 Joe Perches <joe@...ches.com> wrote:
>
> I think the test better if it checks for a SHA1 after fixes.
>
> And IMO
>
> !(foo =~ /bar.../)
>
> is better written as
>
> foo !~ /bar.../
>
> so
>
> if ($in_commit_log &&
> $line =~ /^\s*Fixes:?\s*[0-9a-f]{5,}\b/i &&
> $line !~ /^Fixes: [0-9a-f]{12,40} \(\".*\"\)/)) {
>
> Though it's arguable that the SHA1 should _only_ be length 12
> and not longer.
It should be allowed to be longer - eventaully we will need to move on
from 12 as the repo gets bigger. Also, any line matching /^\s*Fixes:/i
should be checked, because people do add extra words before the SHA1
and sometimes just other text. You will get some hits that are not
meant to be Fixes tags, but very few.
--
Cheers,
Stephen Rothwell
Content of type "application/pgp-signature" skipped
Powered by blists - more mailing lists