From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-4.0 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI,RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by dcvr.yhbt.net (Postfix) with ESMTP id 7A6D21F5A2 for ; Thu, 6 Feb 2020 16:45:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727778AbgBFQpU (ORCPT ); Thu, 6 Feb 2020 11:45:20 -0500 Received: from pb-smtp20.pobox.com ([173.228.157.52]:59625 "EHLO pb-smtp20.pobox.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727593AbgBFQpU (ORCPT ); Thu, 6 Feb 2020 11:45:20 -0500 Received: from pb-smtp20.pobox.com (unknown [127.0.0.1]) by pb-smtp20.pobox.com (Postfix) with ESMTP id 5024FB6A41; Thu, 6 Feb 2020 11:45:18 -0500 (EST) (envelope-from junio@pobox.com) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type:content-transfer-encoding; s=sasl; bh=35XITlQQgITC OpxIil4MNsc0zNs=; b=lF8IUlckLcED0r43sOucAoC+njwuRS1On/Zrl7frM+lq Z1Q6Tn1vFz89g9DGFoEXgyOrth2qVrKNAQgq7YgDX3Pa5Er4XPUG5OsQiT7ANCJV fq3jvWh/oqSdmvBIGXW4cw4dNVfZ0yCGIxgUr/UhdijPfP1wih0aL3m5FeJmVCk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type:content-transfer-encoding; q=dns; s=sasl; b=u4SlTG xpEuqpQ6KjwfnrQS2bAD2ztdVNsoI3ycZG99YfXgy+gWd9SboSntK0+/xfT1TUTc OX6qcH06vqSRAQd3MRS75Sq6CLblbm51tumHpM3CbcsPXAzQuj37V+WtJR2k9mfk NmFPTtGhCL0F3HAtsKdcsVtCgUFlTphHHuzPw= Received: from pb-smtp20.sea.icgroup.com (unknown [127.0.0.1]) by pb-smtp20.pobox.com (Postfix) with ESMTP id 4813BB6A40; Thu, 6 Feb 2020 11:45:18 -0500 (EST) (envelope-from junio@pobox.com) Received: from pobox.com (unknown [34.76.80.147]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pb-smtp20.pobox.com (Postfix) with ESMTPSA id 4B872B6A3F; Thu, 6 Feb 2020 11:45:14 -0500 (EST) (envelope-from junio@pobox.com) From: Junio C Hamano To: =?utf-8?Q?Ren=C3=A9?= Scharfe Cc: "Michael S. Tsirkin" , git@vger.kernel.org Subject: Re: bug? illegal text in commit log References: <20200204010524-mutt-send-email-mst@kernel.org> Date: Thu, 06 Feb 2020 08:45:11 -0800 In-Reply-To: (=?utf-8?Q?=22R?= =?utf-8?Q?en=C3=A9?= Scharfe"'s message of "Tue, 4 Feb 2020 22:10:30 +0100") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 X-Pobox-Relay-ID: 0C4A4A20-4900-11EA-BB23-B0405B776F7B-77302942!pb-smtp20.pobox.com Content-Transfer-Encoding: quoted-printable Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Ren=C3=A9 Scharfe writes: > Like a Lines: header specifying the number of lines in the commit messa= ge? The only part of the workflow that can count the number reliably is format-patch. But the output of format-patch is designed to be edited further, and expecting users to adjust the number when they make such an edit is a bit too much. As nobody in the discussion seem to care any e-mail source other than format-patch, we may probably be able to teach mailinfo that * the first line that=20 - begins with "diff " or "Index", or - is "---" (and nothing else on the line) signals that the line no longer is part of the log * but if it finds a line that begins with "diff --git" (or optionally just "diff "), do not blindly assume that is the end of the log, and instead try to find the first "---" line. If there isn't any "---", then take that "diff" line the beginning of the patch, but if there is, "---" is the end of the message. The latter rule is the new one. And there is no need to change format-patch output.