Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1460773 > unrolled thread

[REGRESSION] get_maintainer: very noisy since '-f' is optional

Started byWolfram Sang <wsa@the-dreams.de>
First post2016-08-11 22:20 +0200
Last post2016-08-11 23:00 +0200
Articles 3 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [REGRESSION] get_maintainer: very noisy since '-f' is optional Wolfram Sang <wsa@the-dreams.de> - 2016-08-11 22:20 +0200
    Re: [REGRESSION] get_maintainer: very noisy since '-f' is optional Joe Perches <joe@perches.com> - 2016-08-11 22:50 +0200
      Re: [REGRESSION] get_maintainer: very noisy since '-f' is optional Wolfram Sang <wsa@the-dreams.de> - 2016-08-11 23:00 +0200

#1460773 — [REGRESSION] get_maintainer: very noisy since '-f' is optional

FromWolfram Sang <wsa@the-dreams.de>
Date2016-08-11 22:20 +0200
Subject[REGRESSION] get_maintainer: very noisy since '-f' is optional
Message-ID<s54Cl-cj-1@gated-at.bofh.it>

[Multipart message — attachments visible in raw view] — view raw

Hi Joe,

commit 4cad35a7ca690eabf0d241062ce9e59693ec03e7 ("get_maintainer.pl:
reduce need for command-line option -f") makes my scripts very noisy.

I regularly use get_maintainer to create CC lists for patch series
generated with coccinelle. These patch series are stored outside my
Linux git repo. Now I get for every vcs_file_exists() a warning from
git-ls-files:

fatal: /home/wsa/Kernel/string-refactor/usb_alloc_urb/patches/sound/usb/0001-ALSA-usb-caiaq-audio-don-t-print-error-when-allocati.patch: '/home/wsa/Kernel/string-refactor/usb_alloc_urb/patches/sound/usb/0001-ALSA-usb-caiaq-audio-don-t-print-error-when-allocati.patch' is outside repository

Git version 2.8.1 here.

Can you take care of that?

Thanks,

   Wolfram

[toc] | [next] | [standalone]


#1460790

FromJoe Perches <joe@perches.com>
Date2016-08-11 22:50 +0200
Message-ID<s555n-nU-11@gated-at.bofh.it>
In reply to#1460773
On Thu, 2016-08-11 at 22:14 +0200, Wolfram Sang wrote:
> Hi Joe,

Hi Wolfram.

One of my favorite xkcd comics: https://xkcd.com/1172/

> commit 4cad35a7ca690eabf0d241062ce9e59693ec03e7 ("get_maintainer.pl:
> reduce need for command-line option -f") makes my scripts very noisy.

> I regularly use get_maintainer to create CC lists for patch series
> generated with coccinelle. These patch series are stored outside my
> Linux git repo. Now I get for every vcs_file_exists() a warning from
> git-ls-files:
> 
> fatal: /home/wsa/Kernel/string-refactor/usb_alloc_urb/patches/sound/usb/0001-ALSA-usb-caiaq-audio-don-t-print-error-when-allocati.patch: '/home/wsa/Kernel/string-refactor/usb_alloc_urb/patches/sound/usb/0001-ALSA-usb-caiaq-audio-don-t-print-error-when-allocati.patch' is outside repository
> 
> Git version 2.8.1 here.
> 
> Can you take care of that?

Maybe this?

diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
index 49a00d5..aed4511 100755
--- a/scripts/get_maintainer.pl
+++ b/scripts/get_maintainer.pl
@@ -2136,9 +2136,11 @@ sub vcs_file_exists {
 
     my $cmd = $VCS_cmds{"file_exists_cmd"};
     $cmd =~ s/(\$\w+)/$1/eeg;		# interpolate $cmd
-
+    $cmd .= " 2>&1";
     $exists = &{$VCS_cmds{"execute_cmd"}}($cmd);
 
+    return 0 if ($? != 0);
+
     return $exists;
 }
 

[toc] | [prev] | [next] | [standalone]


#1460791

FromWolfram Sang <wsa@the-dreams.de>
Date2016-08-11 23:00 +0200
Message-ID<s55f3-rc-9@gated-at.bofh.it>
In reply to#1460790

[Multipart message — attachments visible in raw view] — view raw

> One of my favorite xkcd comics: https://xkcd.com/1172/

Yes, a good one. I hope my usecase of checking patches outside the repo
is not as esoteric, though ;)

> Maybe this?

Seems to work. Thanks!

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web