git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Jay Soffian <jaysoffian@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: [PATCH] warn use of "git diff A..B"
Date: Thu, 24 Mar 2011 11:33:44 -0700	[thread overview]
Message-ID: <7vtyes8j1z.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <AANLkTikjN_90UApfD2rRksDk8qXyE6pJHhd00Aw-Qe7Y@mail.gmail.com> (Jay Soffian's message of "Thu, 24 Mar 2011 14:11:34 -0400")

Jay Soffian <jaysoffian@gmail.com> writes:

> On Wed, Mar 23, 2011 at 5:45 PM, Junio C Hamano <gitster@pobox.com> wrote:
> ... this is not consistent ...
>
>> The new code does not issue a warning against "git diff ..B" that is used
>> as a shorthand for "git diff HEAD B", and "git diff A.." that is used as a
>> shorthand for "git diff A HEAD", respectively.  These are shorter to type
>> and are often useful.
>
> ...with this.

I already _know_ it is not consistent.  My verdict is that shoter-to-type
and being useful trumps that minor consistency argument and that is why
the patch is like so, and that is why the proposed commit log message
clearly describes the choice.

> I use diff A..B all the time, because I've often just used log A..B,
> or I'm about to, and it's one less part of the command line to change.

OK.  I hereby designate you as the official cluebat wearer responsible for
explaining things whenever new people get confused and say that the output
from "git diff A..B" does not match what they expect from "git log A..B",
(and "git diff A...B" vs "git log A...B") on this list.

Thanks ;-).

  parent reply	other threads:[~2011-03-24 18:34 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-23 21:36 [PATCH] diff: remove dead code that flips arguments order Junio C Hamano
2011-03-23 21:45 ` [PATCH] warn use of "git diff A..B" Junio C Hamano
2011-03-24 15:44   ` Jakub Narebski
2011-03-25  8:27     ` Johannes Sixt
2011-03-24 18:11   ` Jay Soffian
2011-03-24 18:16     ` Jay Soffian
2011-03-24 18:33     ` Junio C Hamano [this message]
2011-03-25  9:06   ` Ævar Arnfjörð Bjarmason
2011-03-27 20:03   ` Alex Riesen
2011-03-28 16:53     ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7vtyes8j1z.fsf@alter.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=jaysoffian@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).