On Sun, Sep 18, 2011 at 6:52 PM, Philip Oakley <philipoak...@iee.org> wrote:

> Have a look in the reflog for the step where you commiited the file (time
> for firing up the 'bash' window and some typing;-). It should give you the
> sha1 value for the commit.
> Assuming this is still in your own local repo (which it should be unless
> you actively pruned it), you can check out that sha1 commit. It will be a
> 'detached head' i.e. you won't be on any branch.
> Having checked it out and confirmed it is what you expected, create a new
> branch (you can even tell git the point at which you want the new branch to
> split from current branch), and then you can commit the current state (which
> has the lost commit state) onto the new branch.
> Then it's time to read up on your local 'fast forward' policies, and the
> man page explanations. Hope this helps.
bingo, reflog was the magic word I was trying to remember.  thanks.

You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To post to this group, send email to git-users@googlegroups.com.
To unsubscribe from this group, send email to 
For more options, visit this group at 

Reply via email to