Subject: Re: Removing some files from history

From: Jakub Narebski <[email-masked]>
Date: Fri, 17 Oct 2008 05:20:21 -0700 (PDT)

Please do not toppost, and quote only fragments you are replying to.

"Gennady Kushnir" <[email-masked]> writes:

> thank you for precise instructions.
> 
> however I did not completely understand the part about references
> and reflog what are these? git tags?

git-filter-branch saves old version under refs/original/* namespace.
You have to remove them after making sure that your rewritten history
is correct.  

Additionally git keeps log where branch (tip/head of branch) was in
your repository; this is kind of generalization of ORIG_HEAD, and
allows to recover from such mistakes as wrong "git reset --hard".
Reflog entries from your original history also would pin commits, so
you have to expire reflog.

And finally the commits you have are there in repository, so you have
to "prune" repository to get rid of them.  Reflog entries and
refs/original/* pin those commits, so you have to remove them prior to
pruning.  Pruning simply removes objects which are unreferenced.

> and another question:
> did I understand it right, that I can even make some changes to that
> file in history - not just simply delete one?

Yes, see man git-filter-branch.

-- 
Jakub Narebski
Poland
ShadeHawk on #git