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.1 required=3.0 tests=AWL,BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI,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 1A3B11F4C0 for ; Sun, 20 Oct 2019 06:29:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726291AbfJTG3V (ORCPT ); Sun, 20 Oct 2019 02:29:21 -0400 Received: from aserp2120.oracle.com ([141.146.126.78]:60262 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725916AbfJTG3U (ORCPT ); Sun, 20 Oct 2019 02:29:20 -0400 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x9K6SiIR098640; Sun, 20 Oct 2019 06:28:44 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : to : cc : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=corp-2019-08-05; bh=nUWRZKEHXe6B3aTXbizJaL9c8qWLwRahm0jMX0i5lzY=; b=MRM29o2JUnLNrOU29bkhnVYEmzZt1TOuPRAxG/iYz8QUrpvoPF3VkAIkBWY2oK57AW24 Y4hmeVTKcZuYC5/Gq7zhOEb0S5xNHjCQTGIiqHNtppGvy4Jc/JcB+0zJMNSic3N4zoAN BqzlZ5RhTY1tdpY2eNrxxCu+CTY7gdVLUKkapRdWj+wLdyDpijoTgnR8z/FkhZ7wsF/G hX5xvcZLO2ZqJwoT89J6SEsJIiaG/lqLxIdKb3s20tei8MsvTTigZTg77yZueoTQQ3zM +5FP0ZltTesUGgXbKTwhyj8tpb8fBAfVWsYB7Z3dRT+kfZ9Hl6CVnclVvL7dLMzILM9V Jg== Received: from userp3020.oracle.com (userp3020.oracle.com [156.151.31.79]) by aserp2120.oracle.com with ESMTP id 2vqtepajtk-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 20 Oct 2019 06:28:44 +0000 Received: from pps.filterd (userp3020.oracle.com [127.0.0.1]) by userp3020.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x9K6RvIb175116; Sun, 20 Oct 2019 06:28:43 GMT Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by userp3020.oracle.com with ESMTP id 2vrcmj90jk-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 20 Oct 2019 06:28:43 +0000 Received: from abhmp0022.oracle.com (abhmp0022.oracle.com [141.146.116.28]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id x9K6SeCP016320; Sun, 20 Oct 2019 06:28:40 GMT Received: from [10.175.22.123] (/10.175.22.123) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Sun, 20 Oct 2019 06:28:39 +0000 Subject: Re: email as a bona fide git transport To: Willy Tarreau , "Theodore Y. Ts'o" Cc: Santiago Torres Arias , workflows@vger.kernel.org, Git Mailing List , LKML , Konstantin Ryabitsev , Eric Wong References: <20191016111009.GE13154@1wt.eu> <20191016144517.giwip4yuaxtcd64g@LykOS.localdomain> <56664222-6c29-09dc-ef78-7b380b113c4a@oracle.com> <20191018161547.GG21137@mit.edu> <20191018191456.GI21137@mit.edu> <20191020031716.GA17475@1wt.eu> From: Vegard Nossum Message-ID: <1a259d8d-b3d1-b64e-07c3-ba143b42c442@oracle.com> Date: Sun, 20 Oct 2019 08:28:31 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0 MIME-Version: 1.0 In-Reply-To: <20191020031716.GA17475@1wt.eu> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9415 signatures=668684 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1908290000 definitions=main-1910200063 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9415 signatures=668684 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1908290000 definitions=main-1910200063 Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org On 10/20/19 5:17 AM, Willy Tarreau wrote: > On Fri, Oct 18, 2019 at 03:14:56PM -0400, Theodore Y. Ts'o wrote: >> On Fri, Oct 18, 2019 at 06:50:51PM +0200, Vegard Nossum wrote: >>> The problem I ran into with putting the metadata at the end was >>> detecting where the diff ends. A comment in 'git apply' suggested that >>> detecting the difference between "--" as a diff/signature separator and >>> as part of the diff is nontrivial in the sense that you need to actually >>> do some parsing and keep track of hunk sizes. >> >> Could we cheat by having "git format-patch" add a "Diff-size" in the >> header which gives the number of lines in the diff so git am can just >> count lines to find the Trailer section? > > Be careful with this, it starts like this and ends up with non-editable > patches. I'd rather have git-am use best-effort detection of the end. Expect filesystem developers to come up with a format that uses extents ;-) > Also when dealing with stable backports, I've done a lot of > "cat foo.diff >> bar.patch" to fixup some patches in which I just had > to move some parts around. Having to count lines and edit a counter > somewhere is going to become really painful. I almost have some new patches ready for putting the metadata after the patch using a very bare-bones diff parser (it's actually not that bad), I just need to fix a few corner cases that are causing breakage in the git test suite. Vegard