gpsd-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [gpsd-dev] Please "git gc --aggressive" the gpsd repository?


From: Joshua Judson Rosen
Subject: Re: [gpsd-dev] Please "git gc --aggressive" the gpsd repository?
Date: Sat, 04 Jan 2014 14:06:50 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux)

Greg Troxel <address@hidden> writes:
>
> I tried this on a few repos of mine (which were not the result of
> import/etc. - native git the whole time).  git gc cleaned up a lot,
> mostly from coalescing loose objects.   And --aggressive reduced 1300K
> to 1040K more or less, as a typical case.  The repack with depth=250 did
> exactly the same as gc --aggressive.

I need to use "git repack -f -a" on my fresh gpsd clone to make it shrink.
The actually git-repack command that is run by "git gc --aggressive",
here, appears to be:

        git repack -d -l -f --depth=250 --window=250 \
                   -A --unpack-unreachable=2.weeks.ago

Just the "git repack -f -a" makes it shrink down to 15 MB;
adding "--window=250" makes it go down to 13 MB.

It will balloon up again, of course, and I'm not sure how quickly, but
maybe quickly enough that 15 MB vs. 13 MB isn't really a big deal.
15 MB vs. 100 MB *is* a big deal, though: in response to Greg's
question from further up the thread:

> While cleaning up the public repo seems sensible, how does that affect
> the size of a clone?  clone should be getting objects that are
> referenced, and thus not depend on stray objects.   Or is it about
> receiving compressed objects that are all compressed together into packs
> and thus much better compressed?

Yes, clones appear to be just however big the repo they're cloned from
is--the public repo we both cloned from was 100 MB, so we both had to
download all of that and ended up with our own 100-MB repos.

I tested with a copy of the repo on my own server, and repacking
the remote repo down to 15 or 13 MB does in fact speed up my clone
operation by ~85% :)

-- 
"'tis an ill wind that blows no minds."



reply via email to

[Prev in Thread] Current Thread [Next in Thread]