diff options
author | Jim Meyering <meyering@fb.com> | 2016-03-15 08:17:23 -0700 |
---|---|---|
committer | Jim Meyering <meyering@fb.com> | 2016-03-18 13:27:42 -0700 |
commit | 614c368a74b64bf526c8df5391353feee6a9b7b2 (patch) | |
tree | 01204ad73081d24b74bcdc13f888da0052f5ac56 | |
parent | cce2fd5520bba35cf9b264de2f1b6131304f19d2 (diff) | |
download | grep-614c368a74b64bf526c8df5391353feee6a9b7b2.tar.gz |
maint: avoid spurious "binary file ... matches" in generated THANKS
* Makefile.am (THANKS): Don't apply grep to a stream containing
NUL bytes. Sync this rule from the one in coreutils: it was missing
some improvements.
Reported by Bailes Magio in http://bugs.gnu.org/22899
-rw-r--r-- | Makefile.am | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Makefile.am b/Makefile.am index d04cd792..188d4751 100644 --- a/Makefile.am +++ b/Makefile.am @@ -73,12 +73,12 @@ THANKS: THANKS.in Makefile.am .mailmap thanks-gen $(AM_V_GEN)rm -f $@-t $@; \ { \ $(prologue); echo; \ - { perl -ne '/^$$/.../^$$/ and print' $(srcdir)/THANKS.in \ - | grep -v '^$$' | perl -pe 's/ +/\0/'; \ + { perl -ne '/^$$/.../^$$/ and !/^$$/ and s/ +/\0/ and print' \ + $(srcdir)/THANKS.in; \ git log --pretty=format:'%aN%x00%aE' \ | $(ASSORT) -u; \ } | $(srcdir)/thanks-gen \ - | LC_ALL=en_US.UTF-8 sort -f; \ + | LC_ALL=en_US.UTF-8 sort -k1,1; \ echo; \ printf ';; %s\n' 'Local Variables:' 'coding: utf-8' End:; \ } > $@-t && chmod a-w $@-t && mv $@-t $@ |