[PATCH] git send-email: include [anything]-by: signatures

Subsystems: the rest

STALE3717d

4 messages, 2 authors, 2016-06-15 · open the first message on its own page

[PATCH] git send-email: include [anything]-by: signatures

From: "Michael S. Tsirkin" <mst@redhat.com>
Date: 2016-06-15 22:58:31

Consider [anything]-by: a valid signature.
This includes Tested-by: Acked-by: Reviewed-by: etc.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
---
 git-send-email.perl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/git-send-email.perl b/git-send-email.perl
index ecbf56f..bb9093b 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -1359,7 +1359,7 @@ foreach my $t (@files) {
 	# Now parse the message body
 	while(<$fh>) {
 		$message .=  $_;
-		if (/^(Signed-off-by|Cc): (.*)$/i) {
+		if (/^([A-Za-z-]*-by|Cc): (.*)$/i) {
 			chomp;
 			my ($what, $c) = ($1, $2);
 			chomp $c;
-- 
MST

Re: [PATCH] git send-email: include [anything]-by: signatures

From: "Michael S. Tsirkin" <mst@redhat.com>
Date: 2016-06-15 22:58:35

On Mon, Aug 26, 2013 at 07:57:47PM +0300, Michael S. Tsirkin wrote:
Consider [anything]-by: a valid signature.
This includes Tested-by: Acked-by: Reviewed-by: etc.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Ping.
Any opinion on whether this change is acceptable?
quoted hunk
---
 git-send-email.perl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/git-send-email.perl b/git-send-email.perl
index ecbf56f..bb9093b 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -1359,7 +1359,7 @@ foreach my $t (@files) {
 	# Now parse the message body
 	while(<$fh>) {
 		$message .=  $_;
-		if (/^(Signed-off-by|Cc): (.*)$/i) {
+		if (/^([A-Za-z-]*-by|Cc): (.*)$/i) {
 			chomp;
 			my ($what, $c) = ($1, $2);
 			chomp $c;
-- 
MST
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Re: [PATCH] git send-email: include [anything]-by: signatures

From: Jeff King <hidden>
Date: 2016-06-15 22:58:36

On Sat, Aug 31, 2013 at 10:22:50PM +0300, Michael S. Tsirkin wrote:
On Mon, Aug 26, 2013 at 07:57:47PM +0300, Michael S. Tsirkin wrote:
quoted
Consider [anything]-by: a valid signature.
This includes Tested-by: Acked-by: Reviewed-by: etc.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Ping.
Any opinion on whether this change is acceptable?
I was left confused by your commit message, as it wasn't clear to me
what a "signature" is. But the point of it seems to be that people
mention others in commit messages using "X-by:" pseudo-headers besides
"signed-off-by", and you want to cc them along with the usual S-O-B.

That seems like a reasonable goal, but I have two concerns.

One, I would think the utility of this would be per-project, depending
on what sorts of things people in a particular project put in
pseudo-headers.  Grepping the kernel history shows that most X-by
headers have a person on the right-hand side, though quite often it is
not a valid email address (on the other hand, quite a few s-o-b lines in
the kernel do not have a valid email).

And two, the existing options for enabling/disabling this code all
explicitly mention signed-off-by, which becomes awkward. You did not
update the documentation in your patch, but I think you would end up
having to explain that "--supress-cc=sob" and "--signed-off-by-cc"
really mean "all pseudo-header lines ending in -by".

So I think it might be a nicer approach to introduce a new "suppress-cc"
class that means "all pseudo-header tokens ending in -by" or similar.
We might even want the new behavior on by default, but it would at least
give the user an escape hatch if their project generates a lot of false
positives.

-Peff

Re: [PATCH] git send-email: include [anything]-by: signatures

From: "Michael S. Tsirkin" <mst@redhat.com>
Date: 2016-06-15 22:58:36

On Tue, Sep 03, 2013 at 02:35:35AM -0400, Jeff King wrote:
On Sat, Aug 31, 2013 at 10:22:50PM +0300, Michael S. Tsirkin wrote:
quoted
On Mon, Aug 26, 2013 at 07:57:47PM +0300, Michael S. Tsirkin wrote:
quoted
Consider [anything]-by: a valid signature.
This includes Tested-by: Acked-by: Reviewed-by: etc.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Ping.
Any opinion on whether this change is acceptable?
I was left confused by your commit message, as it wasn't clear to me
what a "signature" is. But the point of it seems to be that people
mention others in commit messages using "X-by:" pseudo-headers besides
"signed-off-by", and you want to cc them along with the usual S-O-B.

That seems like a reasonable goal, but I have two concerns.

One, I would think the utility of this would be per-project, depending
on what sorts of things people in a particular project put in
pseudo-headers.  Grepping the kernel history shows that most X-by
headers have a person on the right-hand side, though quite often it is
not a valid email address (on the other hand, quite a few s-o-b lines in
the kernel do not have a valid email).

And two, the existing options for enabling/disabling this code all
explicitly mention signed-off-by, which becomes awkward. You did not
update the documentation in your patch, but I think you would end up
having to explain that "--supress-cc=sob" and "--signed-off-by-cc"
really mean "all pseudo-header lines ending in -by".

So I think it might be a nicer approach to introduce a new "suppress-cc"
class that means "all pseudo-header tokens ending in -by" or similar.
We might even want the new behavior on by default, but it would at least
give the user an escape hatch if their project generates a lot of false
positives.

-Peff
I guess there's always cccmd, no?

-- 
MST
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help