Re: [PATCH v3 11/11] Unify appending signoff in format-patch, commit and sequencer
- From
Brandon Casey <drafnel@gmail.com>
- Date
- Feb 10, 2013, 23:55 UTC
- Message-ID
- <CA+sFfMduqEJPtDQyTe2n7QiLmDpTN7MzLGrUNf1hWf-h0rGzvA@mail.gmail.com>
- In-Reply-To
- <20130128033921.GP8206@elie.Belkin>
On Sun, Jan 27, 2013 at 7:39 PM, Jonathan Nieder <jrnieder@gmail.com> wrote:
Show 16 quoted lines
> Brandon Casey wrote:
>
>> --- a/log-tree.c
>> +++ b/log-tree.c
> [...]
>> @@ -208,94 +207,6 @@ void show_decorations(struct rev_info *opt, struct commit *commit)
>> putchar(')');
>> }
>>
>> -/*
>> - * Search for "^[-A-Za-z]+: [^@]+@" pattern. It usually matches
>> - * Signed-off-by: and Acked-by: lines.
>> - */
>
> That's stricter than the test from sequencer.c. Maybe it's worth
> stealing to avoid false positives?No, we don't want this stricter test because it assumes that the right-hand side of "[-A-Za-z]+:" will be an email address, so it requires an '@' to exist. We want to be able to support lines that do not have email addresses on the right-hand side like:
Bug: XXX Change-Id: XXX
and perhaps eventually
Cherry-picked-from: XXX
The current series has retained the same basic test for an rfc2822-like line that existed in sequencer.c and would interpret a line that contains only a colon as conforming. A follow-on patch could require that at least one character precede the colon, but that would be a change in behavior that is not the goal of this series.
-Brandon