mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: Jani Nikula <jani.nikula@intel.com>,
	linux-kernel@vger.kernel.org,  linux-doc@vger.kernel.org,
	Andrew Morton <akpm@linux-foundation.org>
Cc: Jonathan Corbet <corbet@lwn.net>
Subject: Re: [PATCH 1/2] get_maintainer: add --bug option to print bug reporting info
Date: Fri, 16 Aug 2024 20:54:48 -0700	[thread overview]
Message-ID: <3c0658cc4a5a174d149175bd9b8f6ce3dfe75574.camel@perches.com> (raw)
In-Reply-To: <20240815113450.3397499-1-jani.nikula@intel.com>

On Thu, 2024-08-15 at 14:34 +0300, Jani Nikula wrote:
> For example Documentation/adming-guide/bug-hunting.rst suggest using
> get_maintainer.pl to get a list of maintainers and mailing lists to
> report bugs to, while a number of subsystems and drivers explicitly use
> the "B:" MAINTAINERS entry to direct bug reports at issue trackers
> instead of mailing lists and people.
> 
> Add the --bug option to get_maintainer.pl to print the bug reporting
> URIs, if any.

Seems sensible, thanks.

Acked-by: Joe Perches <joe@perches.com>

> 
> Cc: Joe Perches <joe@perches.com>
> Cc: Jonathan Corbet <corbet@lwn.net>
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
> ---
>  scripts/get_maintainer.pl | 17 +++++++++++++++--
>  1 file changed, 15 insertions(+), 2 deletions(-)
> 
> diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
> index ee1aed7e090c..5ac02e198737 100755
> --- a/scripts/get_maintainer.pl
> +++ b/scripts/get_maintainer.pl
> @@ -54,6 +54,7 @@ my $output_section_maxlen = 50;
>  my $scm = 0;
>  my $tree = 1;
>  my $web = 0;
> +my $bug = 0;
>  my $subsystem = 0;
>  my $status = 0;
>  my $letters = "";
> @@ -271,6 +272,7 @@ if (!GetOptions(
>  		'scm!' => \$scm,
>  		'tree!' => \$tree,
>  		'web!' => \$web,
> +		'bug!' => \$bug,
>  		'letters=s' => \$letters,
>  		'pattern-depth=i' => \$pattern_depth,
>  		'k|keywords!' => \$keywords,
> @@ -320,13 +322,14 @@ if ($sections || $letters ne "") {
>      $status = 0;
>      $subsystem = 0;
>      $web = 0;
> +    $bug = 0;
>      $keywords = 0;
>      $keywords_in_file = 0;
>      $interactive = 0;
>  } else {
> -    my $selections = $email + $scm + $status + $subsystem + $web;
> +    my $selections = $email + $scm + $status + $subsystem + $web + $bug;
>      if ($selections == 0) {
> -	die "$P:  Missing required option: email, scm, status, subsystem or web\n";
> +	die "$P:  Missing required option: email, scm, status, subsystem, web or bug\n";
>      }
>  }
>  
> @@ -631,6 +634,7 @@ my %hash_list_to;
>  my @list_to = ();
>  my @scm = ();
>  my @web = ();
> +my @bug = ();
>  my @subsystem = ();
>  my @status = ();
>  my %deduplicate_name_hash = ();
> @@ -662,6 +666,11 @@ if ($web) {
>      output(@web);
>  }
>  
> +if ($bug) {
> +    @bug = uniq(@bug);
> +    output(@bug);
> +}
> +
>  exit($exit);
>  
>  sub self_test {
> @@ -847,6 +856,7 @@ sub get_maintainers {
>      @list_to = ();
>      @scm = ();
>      @web = ();
> +    @bug = ();
>      @subsystem = ();
>      @status = ();
>      %deduplicate_name_hash = ();
> @@ -1069,6 +1079,7 @@ MAINTAINER field selection options:
>    --status => print status if any
>    --subsystem => print subsystem name if any
>    --web => print website(s) if any
> +  --bug => print bug reporting info if any
>  
>  Output type options:
>    --separator [, ] => separator for multiple entries on 1 line
> @@ -1382,6 +1393,8 @@ sub add_categories {
>  		push(@scm, $pvalue . $suffix);
>  	    } elsif ($ptype eq "W") {
>  		push(@web, $pvalue . $suffix);
> +	    } elsif ($ptype eq "B") {
> +		push(@bug, $pvalue . $suffix);
>  	    } elsif ($ptype eq "S") {
>  		push(@status, $pvalue . $suffix);
>  	    }


  parent reply	other threads:[~2024-08-17  4:33 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-15 11:34 Jani Nikula
2024-08-15 11:34 ` [PATCH 2/2] Documentation: admin-guide: direct people to bug trackers, if specified Jani Nikula
2024-08-17  3:54   ` Joe Perches
2024-08-28 14:04   ` Joe Perches
2024-08-17  3:54 ` Joe Perches [this message]
2024-08-26 22:10 ` [PATCH 1/2] get_maintainer: add --bug option to print bug reporting info Jonathan Corbet

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=3c0658cc4a5a174d149175bd9b8f6ce3dfe75574.camel@perches.com \
    --to=joe@perches.com \
    --cc=akpm@linux-foundation.org \
    --cc=corbet@lwn.net \
    --cc=jani.nikula@intel.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@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

all inboxes | Powered by JetHome®