workflows.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Geert Uytterhoeven <geert@linux-m68k.org>
To: Greg KH <gregkh@linuxfoundation.org>
Cc: workflows@vger.kernel.org
Subject: Re: script to check "Fixes:" tags
Date: Fri, 27 Sep 2019 21:00:37 +0200	[thread overview]
Message-ID: <CAMuHMdXFODjJpgbH==PLWsU1KL-7oDXS_u_wMZ99v-KEnt_QKw@mail.gmail.com> (raw)
In-Reply-To: <20190927183557.GA1805907@kroah.com>

Hi Greg,

On Fri, Sep 27, 2019 at 8:36 PM Greg KH <gregkh@linuxfoundation.org> wrote:
> On Fri, Sep 27, 2019 at 08:06:18PM +0200, Geert Uytterhoeven wrote:
> > On Fri, Sep 27, 2019 at 8:01 PM Greg KH <gregkh@linuxfoundation.org> wrote:
> > > On Fri, Sep 27, 2019 at 09:49:55AM +0200, Geert Uytterhoeven wrote:
> > > > On Thu, Sep 26, 2019 at 9:51 PM Greg KH <gregkh@linuxfoundation.org> wrote:
> > > > > Since this list was created to share scripts, here's one that I
> > > > > currently use to test that the "Fixes:" tags are correct on a commit.  I
> > > > > run it on all patches that I accept into my trees, after getting emails
> > > > > from Stephen one too many times :)
> > > > >
> > > > > It's almost entirely based on Stephen's original script, but has been
> > > > > changed a bit in formatting and usage to be a stand-alone script that
> > > > > anyone can use.
> > > > >
> > > > > To use:
> > > > >         verify_fixes.sh GIT_RANGE
> > > > >
> > > > > if all is good, script will print nothing out and exit with success.  If
> > > > > there is a problem it will be printed out and the script will exit with
> > > > > an error that you can check from any other program.
> > > > >
> > > > > It it 'shellcheck' clean, but I'm sure that there are other things wrong
> > > > > with it, so feel free to point out problems.
> > > >
> > > > Thanks!
> > > >
> > > > > And should stuff like this be in the kernel tree itself?
> > > >
> > > > Probably this should be integrated into checkpatch.pl?
> > >
> > > I can't run checkpatch.pl on everything as sometimes I need to take
> > > patches that do not pass it :)
> >
> > Running checkpatch and taking patches are not mutually exclusive ;-)
> >
> > > checkpatch.pl is supposed to check for s-o-b but for some reason I don't
> > > think it does all of the checking that my other script does.  Or at
> > > least I haven't noticed it.
> >
> > May be true, but it doesn't help to fragment the checking script space.
> > Just like we just want to run get_maintainer.pl, we just want to run
> > checkpatch.pl, don't we?
>
> do we?

https://www.kernel.org/doc/html/v4.17/process/submitting-patches.html#style-check-your-changes

> Again, I can't do it in my "workflow" at the moment.  This list was for
> people to post what they do and get comments.

You're applying patches from a mailbox folder, right?
So you can run checkpatch against all individual patches in the folder
using:

    formail -s scripts/checkpatch.pl < /path/to/the/mbox/to/apply

BTW, that also applies to patchwork bundles, which is what I started
using recently.

> And a comment of "don't use the tool you have, use something else that
> doesn't do what you really need to do", isn't all that helpful :)

Actually that also applies in reverse, I do use checkpatch.pl ;-)

Use and improve the shared tool that comes with the kernel, instead of
using the one in your cathedral? Unless I'm missing something, that's
one of the general ideas behind this...

> I just noticed that checkpatch can handle a git range, so I'll revisit
> it and see if I can "just test one thing" with it or not, next week.

That assumes the patches have been applied already...
Which is fine for maintainers taking pull requests.

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

  reply	other threads:[~2019-09-27 19:00 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-26 19:51 script to check "Fixes:" tags Greg KH
2019-09-27  7:08 ` Krzysztof Kozlowski
2019-09-27  7:49 ` Geert Uytterhoeven
2019-09-27 12:01   ` Rob Herring
2019-09-27 18:03     ` Greg KH
2019-09-27 18:01   ` Greg KH
2019-09-27 18:06     ` Geert Uytterhoeven
2019-09-27 18:35       ` Greg KH
2019-09-27 19:00         ` Geert Uytterhoeven [this message]
2019-09-27 19:46           ` Theodore Y. Ts'o

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='CAMuHMdXFODjJpgbH==PLWsU1KL-7oDXS_u_wMZ99v-KEnt_QKw@mail.gmail.com' \
    --to=geert@linux-m68k.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=workflows@vger.kernel.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).