git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Retrieving a file at a before a specified commit
@ 2013-05-29  6:47 Erik de Castro Lopo
  2013-05-29  7:58 ` Jeff King
  0 siblings, 1 reply; 8+ messages in thread
From: Erik de Castro Lopo @ 2013-05-29  6:47 UTC (permalink / raw)
  To: git

Hi all,

I have a commit like this:

    commit 4d77a3cee01db0412956d40875c79f51ac745acc
    tree 3443c9f633114c3bd2e015453a8c55a171e62b53
    parent 340d808ade8a79857bec40770f0eb4f98224c53d
    author ....
    committer .....

which modifies file A/B/C (ie specifically does not add, but changes
an existing file in the repo).

I would then like to retrive the version of the file A/B/C before
commit 4d77a3cee by using the parent commit 340d808a:

   git show 340d808ade8a79857bec40770f0eb4f98224c53d:A/B/C

which works for most files/commits I try this with, but doesn't work
in one particular case.

Questions:

- Is my understanding of the above git command incorrect?
- Is this a corrupt repo? Is there some way to check?
- Is there some explaination of why I can't get the previous version
  of that file?

Appreciate any light that could be shed on this.

Cheers,
Erik
-- 
----------------------------------------------------------------------
Erik de Castro Lopo
http://www.mega-nerd.com/

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2013-05-30  3:19 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-05-29  6:47 Retrieving a file at a before a specified commit Erik de Castro Lopo
2013-05-29  7:58 ` Jeff King
2013-05-30  0:49   ` Erik de Castro Lopo
2013-05-30  0:59     ` Erik de Castro Lopo
2013-05-30  2:27       ` Junio C Hamano
2013-05-30  3:18         ` Erik de Castro Lopo
2013-05-30  2:34     ` Jeff King
2013-05-30  3:19       ` Erik de Castro Lopo

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).