Thread (3 messages) flat view 3 messages, 3 authors, 2016-06-15

Re: Re : 2 questions on git-send-email usage

From: Linus Torvalds <torvalds@osdl.org>
Date: 2016-06-15 22:42:33

Possibly related (same subject, not in this thread)


On Wed, 12 Jul 2006, Franck Bui-Huu wrote:
[PATCH] Add a newline before appending "Signed-off-by:"

It looks nicer.
Yes. However, I think the sign-off detection is a bit broken (quite 
independently of your patch).

A number of people end up capitalizing the sign-off differently, so you 
have lines like "Signed-Off-By: Xy Zzy [off-list ref]".

Also, at least for the kernel, we often have alternative formats, like

	Acked-by: Elliot Xavier Ample [off-list ref]

and for that case, adding the extra newline is actually bad.

So I would suggest a totally different approach: instead of using 
"strstr(comments, signed_off_by)", it would probably be much better to 
just look for the last non-empty line, and see if it matches the format

	"^[nonspace]*: .*@.*$"

(yeah, that's not a valid regexp, but you get the idea).

On a slightly related note, I absolutely _hate_ how cherry-picking adds 
"(cherry-picked from commit <sha1>)" at the end. It's wrong for so many 
reasons, one of them being that it then breaks things like this, but the 
main one being that <sha1> will quite often actually end up not even 
_existing_ in the resulting archive (you cherry-picked from your private 
branch, and even if you keep your branch, you don't necessarily push it 
out).

Junio, can we make the default _not_ to do it, please?

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