Git development
 help / color / mirror / Atom feed
From: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr>
To: Ralf Thielow <ralf.thielow@gmail.com>
Cc: git <git@vger.kernel.org>
Subject: Re: Bug? Files are losing history after subtree merge
Date: Wed, 02 Oct 2013 22:21:36 +0200	[thread overview]
Message-ID: <vpqy56bjuen.fsf@anie.imag.fr> (raw)
In-Reply-To: <CAN0XMO+y3Cwsz5LwbmzHBe31Rf-RwMykynLmvmqUsxY8f+1dsQ@mail.gmail.com> (Ralf Thielow's message of "Wed, 2 Oct 2013 22:07:53 +0200")

Ralf Thielow <ralf.thielow@gmail.com> writes:

> Thanks for explanation.
> I knew the history of the repo is there, but the history of single files
> (and the ability to look at it)

There is no such thing as "single file history" in Git. Git knows about
the history of the project, and knows which files were there at each
commit. Then, some commands can walk through history following the
history of a file. "git blame" is very good at it, and should work with
subtree merges. "git log --follow" is a quick hack that nobody bothered
to fix up to now (sadly).

You can use workarounds like

  git log -- '*git-gui.sh'

(from the toplevel), to view each commit that touched a file whose name
ends with git-gui.sh. It won't follow actual renames, and may show false
positive if you have several files with the same basename. But it may
help.

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/

  parent reply	other threads:[~2013-10-02 20:21 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-02 19:20 Bug? Files are losing history after subtree merge Ralf Thielow
2013-10-02 19:42 ` Matthieu Moy
2013-10-02 20:10   ` Ralf Thielow
     [not found]   ` <CAN0XMO+y3Cwsz5LwbmzHBe31Rf-RwMykynLmvmqUsxY8f+1dsQ@mail.gmail.com>
2013-10-02 20:21     ` Matthieu Moy [this message]
2013-10-02 20:44       ` Ralf Thielow

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=vpqy56bjuen.fsf@anie.imag.fr \
    --to=matthieu.moy@grenoble-inp.fr \
    --cc=git@vger.kernel.org \
    --cc=ralf.thielow@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