git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff King <peff@peff.net>
To: Ralf Thielow <ralf.thielow@googlemail.com>
Cc: git <git@vger.kernel.org>
Subject: Re: log: option "--follow" not the default for a single file?
Date: Thu, 1 Dec 2011 13:52:30 -0500	[thread overview]
Message-ID: <20111201185230.GB2873@sigill.intra.peff.net> (raw)
In-Reply-To: <CAN0XMOJGm1frOi7FEke7LfHCSBt2DRn_npkdKe0m3qZ=hQPNHw@mail.gmail.com>

On Wed, Nov 30, 2011 at 07:38:23PM +0100, Ralf Thielow wrote:

> >     pathspec. That may happen to match a single file in the current
> >     revision, but to git it is actually a prefix-limiting pattern, and
> Is it possible to detect the case of a single file in the current
> revisionand use "--follow" by default for exactly that?

It's possible, but it is changing the meaning of "git log foo". With
the current code, even if "foo" is currently a file, it will match
"foo/bar" in a prior revision. Switching this to "--follow" will not.

-Peff

  reply	other threads:[~2011-12-01 18:52 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-29 18:25 log: option "--follow" not the default for a single file? Ralf Thielow
2011-11-30  6:37 ` Jeff King
2011-11-30 18:27   ` Junio C Hamano
2011-11-30 18:38   ` Ralf Thielow
2011-12-01 18:52     ` Jeff King [this message]
2011-12-01 20:28       ` Ralf Thielow
2011-12-01 20:36         ` Jeff King

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=20111201185230.GB2873@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=git@vger.kernel.org \
    --cc=ralf.thielow@googlemail.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).