git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Steinar Bang <sb@dod.no>
Cc: git@vger.kernel.org
Subject: Re: Is there a "--follow" equvalent argument to git-rev-list?
Date: Mon, 28 Nov 2011 11:53:46 -0800	[thread overview]
Message-ID: <7vaa7guiph.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <87vcq4zg6p.fsf@dod.no> (Steinar Bang's message of "Mon, 28 Nov 2011 11:37:02 +0100")

[administrivia: do not use Mail-Followup-To here]

Steinar Bang <sb@dod.no> writes:

> Is there an argument to "git rev-list" that will make it track across
> renames?

There isn't, and it is more or less deliberate.

The "log --follow" is not meant as anything more than a checkbox hack. The
intended audience of "rev-list" is scripts that reads plumbing output and
it is expected to be capable of doing all of what "follow" does and more.
It can notice that the path you were following has disappeared at a
particular commit, see what other paths (notice the plural, which is not
what --follow does) in the older tree may have contributed the contents of
the newly added path by running "diff-tree -M" (or -C), etc. That way the
scripts can even notice a case where a file you were following originally
were two separate files that the commit merged into one, which "follow"
would never do.

      reply	other threads:[~2011-11-28 19:53 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-28 10:37 Is there a "--follow" equvalent argument to git-rev-list? Steinar Bang
2011-11-28 19:53 ` Junio C Hamano [this message]

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=7vaa7guiph.fsf@alter.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=sb@dod.no \
    /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).