From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-3.5 required=3.0 tests=AWL,BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI shortcircuit=no autolearn=ham autolearn_force=no version=3.4.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by dcvr.yhbt.net (Postfix) with ESMTP id 321951F404 for ; Fri, 10 Aug 2018 21:12:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727235AbeHJXni (ORCPT ); Fri, 10 Aug 2018 19:43:38 -0400 Received: from mout.gmx.net ([212.227.17.22]:49507 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727173AbeHJXni (ORCPT ); Fri, 10 Aug 2018 19:43:38 -0400 Received: from [192.168.0.129] ([37.201.193.145]) by mail.gmx.com (mrgmx102 [212.227.17.168]) with ESMTPSA (Nemesis) id 0MQ7sF-1fstGs2G7n-005LLG; Fri, 10 Aug 2018 23:12:01 +0200 Date: Fri, 10 Aug 2018 23:12:03 +0200 (DST) From: Johannes Schindelin X-X-Sender: virtualbox@gitforwindows.org To: Eric Sunshine cc: Thomas Gummerer , gitgitgadget@gmail.com, Git List , Junio C Hamano Subject: Re: [PATCH v4 05/21] range-diff: also show the diff between patches In-Reply-To: Message-ID: References: <94afaeaf224563effda7b3c0b8939567302d2ba1.1532210683.git.gitgitgadget@gmail.com> <20180729190359.GD2734@hank.intra.tgummerer.com> <20180729214543.GD9955@hank.intra.tgummerer.com> <20180730212606.GL9955@hank.intra.tgummerer.com> User-Agent: Alpine 2.21.1 (DEB 209 2017-03-23) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII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fpSZmIbzgTwEQMySItMWz7b1/ht0A N3jgatq Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Hi Eric, On Mon, 30 Jul 2018, Eric Sunshine wrote: > On Mon, Jul 30, 2018 at 5:26 PM Thomas Gummerer wrote: > > On 07/30, Johannes Schindelin wrote: > > > On Sun, 29 Jul 2018, Thomas Gummerer wrote: > > > > There's one more thing that I noticed here: > > > > > > > > git range-diff --no-patches > > > > fatal: single arg format requires a symmetric range > > > > > > > I immediately thought of testing for a leading `-` of the remaining > > > argument, but I could imagine that somebody enterprisey uses > > > > > > git range-diff -- -my-first-attempt...-my-second-attempt > > > > > > and I do not really want to complexify the code... Ideas? > > > > Good point. I can't really come up with a good option right now > > either. It's not too bad, as users just typed the command, so it > > should be easy enough to see from the previous line what went wrong. > > I think you can attain the desired behavior by making a final > parse_options() call with empty 'options' list after the call to > diff_setup_done(). It's pretty much a one-line fix, but can probably > be done as an incremental change rather than rerolling. But then we would have to keep `--` in the first, and not in the second parse_options() call, right? We would also have to handle that `--` properly in the loop that calls diff_opt_parse(), I think. A bit more involved than just a one-line fix, but I guess I'll give it a try. Ciao, Dscho