From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-4.4 required=3.0 tests=AWL,BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD shortcircuit=no autolearn=ham autolearn_force=no version=3.4.0 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by dcvr.yhbt.net (Postfix) with ESMTP id 7A82A1F6C1 for ; Wed, 17 Aug 2016 09:20:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752228AbcHQJUm (ORCPT ); Wed, 17 Aug 2016 05:20:42 -0400 Received: from mout.gmx.net ([212.227.15.15]:49259 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751662AbcHQJUl (ORCPT ); Wed, 17 Aug 2016 05:20:41 -0400 Received: from virtualbox ([37.24.141.212]) by mail.gmx.com (mrgmx003) with ESMTPSA (Nemesis) id 0LhOvA-1anfkP10iG-00mZis; Wed, 17 Aug 2016 11:13:45 +0200 Date: Wed, 17 Aug 2016 11:13:43 +0200 (CEST) From: Johannes Schindelin X-X-Sender: virtualbox@virtualbox To: Remi Galan Alfonso cc: Stephen Morton , Jeff King , Stefan Beller , git@vger.kernel.org Subject: Re: git cherry-pick conflict error message is deceptive when cherry-picking multiple commits In-Reply-To: <968827697.1226723.1471337060482.JavaMail.zimbra@ensimag.grenoble-inp.fr> Message-ID: References: <09d485df-7d14-97f8-9db9-e3db7512bd68@nokia.com> <968827697.1226723.1471337060482.JavaMail.zimbra@ensimag.grenoble-inp.fr> User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Provags-ID: V03:K0:3eqo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Rz BPLq9gI Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Hi, On Tue, 16 Aug 2016, Remi Galan Alfonso wrote: > Stephen Morton writes: > > + if (multiple_commits) > > + advise(_("after resolving the conflicts, > > mark the corrected paths with 'git add ' or 'git rm '\n" > > + "then continue with 'git %s > > --continue'\n" > > + "or cancel with 'git %s > > --abort'" ), action_name(opts), action_name(opts)); > > + else > > + advise(_("after resolving the > > conflicts, mark the corrected paths\n" > > + "with 'git add ' or 'git > > rm '\n" > > + "and commit the result with > > 'git commit'")); > > In both cases (multiple_commits or not), the beginning of the advise > is nearly the same, with only a '\n' in the middle being the > difference: > > multiple_commits: > "after resolving the conflicts, mark the corrected paths with 'git > add ' or 'git rm '\n" > > !multiple_commits: > "after resolving the conflicts, mark the corrected paths\n with 'git > add ' or 'git rm '\n" > ~~~~~~~^ > > In 'multiple_commits' case the advise is more than 80 characters long, > did you forget the '\n' in that case? > > If you end up using the same beginning of advice, maybe it's possible > to give it before the 'if(multiple_commits)' and avoid duplication of > the lines. I concur with this, and also with Christian's advice to append the parameter consistently as last one, and also with renaming it to "last_commit". Ciao, Johannes