Re: git am and the wrong chunk of ---

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08/10/2012 12:36 PM, Jeff King wrote:
> On Thu, Aug 09, 2012 at 05:13:51PM -0700, H. Peter Anvin wrote:
> 
>> I have some contributors who consistently put their commentary
>> *before* the "---" line rather than *after* it, presumably with the
>> notion that it is some kind of "cover text".  This messes with "git
>> am", and so I end up having to edit those posts manually.
>>
>> I have tried git am --scissors and it doesn't seem to solve the problem.
>>
>> Is there any other option which can be used to automatically process
>> such a patch?
> 
> If I understand your issue, somebody is writing:
> 
> 
>      From: them
>      To: you
>      Date: ...
>      Subject: [PATCH] subject line
> 
>      commit message body
>      ....
> 
>      some cover letter material that should go below the "---"
>      ---
>        [diffstat + diff]
> 
> 
> How do you know when the commit message body ends, and the cover letter
> begins? We already have two machine-readable formats for separating the
> two ("---" after the commit message, and "-- >8 --" scissors before). Is
> there some machine-readable hint? Is it always the paragraph before the
> "---"? Chopping that off unconditionally seems like a dangerous
> heuristic.
> 

End of SOB lines might be a good cutoff, if they're present. I've never
seen anyone put commit message text below them anyway.

-- 
Andreas Ericsson                   andreas.ericsson@xxxxxx
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231

Considering the successes of the wars on alcohol, poverty, drugs and
terror, I think we should give some serious thought to declaring war
on peace.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]