GNU bug report logs - #60218
[PATCH 0/2] New teams.scm 'get-maintainer' command (for integration with patman)

Previous Next

Package: guix-patches;

Reported by: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

Date: Tue, 20 Dec 2022 13:59:01 UTC

Severity: normal

Tags: patch

Done: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Ricardo Wurmus <rekado <at> elephly.net>
To: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
Cc: Josselin Poiret <dev <at> jpoiret.xyz>, Tobias Geerinckx-Rice <me <at> tobias.gr>, Simon Tournier <zimon.toutoune <at> gmail.com>, Mathieu Othacehe <othacehe <at> gnu.org>, Ludovic Courtès <ludo <at> gnu.org>, Christopher Baines <mail <at> cbaines.net>, 60218 <at> debbugs.gnu.org
Subject: [bug#60218] [PATCH 1/2] teams: Add a "get-maintainer" command.
Date: Sun, 25 Dec 2022 00:15:39 +0100
Hi Maxim,

> This can be used as a compatibility mode with the get_maintainer.pl Perl
> script included in the Linux (or U-Boot) source tree.
>
> * etc/teams.scm.in (git-patch->commit-id): New procedure.
> (main) <get-maintainer>: Register new command.  Document it.

Interesting.

> @@ -616,6 +627,14 @@ (define (main . args)
>      (("cc-members" rev-start rev-end)
>       (apply cc (find-team-by-scope
>                  (diff-revisions rev-start rev-end))))
> +    (("get-maintainer" patch-file)
> +     (let* ((rev-end (git-patch->commit-id patch-file))
> +            (rev-start (string-append rev-end "^")))

This is to get the changes introduced by this patch-file right?  In a
format that allows you to use “diff-revisions” below, which you need to
run find-team-by-scope.

> +       (apply main "list-members"
> +              (map symbol->string
> +                   (map team-id
> +                        (find-team-by-scope
> +                         (diff-revisions rev-start rev-end)))))))

Here I’d do

    (map (compose symbol->string team-id) …)

instead of mapping twice.

I haven’t used get_maintainer.pl before, but I don’t object to this
change if it’s useful to you.

-- 
Ricardo




This bug report was last modified 2 years and 132 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.