Re: Trying to use git-filter-branch to compress history by removing large, obsolete binary files
- From
Elijah Newren <newren@gmail.com>
- Date
- Oct 7, 2007, 23:38 UTC
- Message-ID
- <51419b2c0710071638p6dcc0c7cm2a813c22758e6f32@mail.gmail.com>
- In-Reply-To
- <Pine.LNX.4.64.0710080028301.4174@racer.site>
Hi,
On 10/7/07, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
> On Sun, 7 Oct 2007, Elijah Newren wrote:
<snip>
Show 10 quoted lines
> > $ git clone test test2 > > <snip> > > $ du -hs test > > 11M test > > $ du -hs test2 > > 11M test2 > > > > Any other ideas? > > Yep. Maybe it is necessary to run "git gc" in test2.
Sweet, finally solved! That brings test2 down to 340K.
However, the solution seems somewhat involved...it requires running git-filter-branch, git reset, removing the .git/refs/original/ directory, editing .git/packed-refs in some editor, running git reflog expire, cloning the resulting repository, and running git gc yet again. It seems like there has to be an easier way. (Anyone have one?)
Oh, and git-filter-branch could really use some explanatory note about how to actually complete rewriting the history.
Thanks, Elijah