* git gc and git repack
@ 2007-03-06 16:13 Sergio Callegari
2007-03-06 21:13 ` Johannes Schindelin
0 siblings, 1 reply; 2+ messages in thread
From: Sergio Callegari @ 2007-03-06 16:13 UTC (permalink / raw)
To: git
Hi,
I am puzzled by a different behavior when doing housekeeping with git-gc and
git-repack:
On a repository I have, git gc gives:
Generating pack...
Done counting 75 objects.
Deltifying 75 objects.
100% (75/75) done
Writing 75 objects.
100% (75/75) done
Total 75 (delta 26), reused 68 (delta 26)
Pack pack-a989a4c4c7454874220cf502865ab9a28952499f created.
Removing unused objects 100%...
Done.
while git repack -a -d gives
Generating pack...
Done counting 143 objects.
Deltifying 143 objects.
100% (143/143) done
Writing 143 objects.
100% (143/143) done
Total 143 (delta 49), reused 120 (delta 31)
Pack pack-d17fd54437f04fbde34088909e31e95718e7b8c5 created.
Removing unused objects 100%...
Done.
Why is a different number of objects being considered in the two case, with git
repack considering more objects and producing a different pack? Also, the
package produced by repack turns out to be much larger than the one by git gc...
In any case, both packages turn out to be git-fsck clean...
I suspect, this has to to with my repository using alternates... (in fact git-gc
and git-repack start behaving identically if I pass the -l (local) option to
repack... can anyone confirm that this is the only difference?
Also can anybody confirm whether git repack -a -d actually includes in the pack
also _all_ the "borrowed" objects? I.e. if it is in fact a way to convert a
repository that borrows objects into one that is self-standing?
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: git gc and git repack
2007-03-06 16:13 git gc and git repack Sergio Callegari
@ 2007-03-06 21:13 ` Johannes Schindelin
0 siblings, 0 replies; 2+ messages in thread
From: Johannes Schindelin @ 2007-03-06 21:13 UTC (permalink / raw)
To: Sergio Callegari; +Cc: git
Hi,
On Tue, 6 Mar 2007, Sergio Callegari wrote:
> I am puzzled by a different behavior when doing housekeeping with git-gc and
> git-repack:
>
> [...]
> Done counting 75 objects.
> [...]
>
> while git repack -a -d gives
>
> Done counting 143 objects.
>
> I suspect, this has to to with my repository using alternates... (in
> fact git-gc and git-repack start behaving identically if I pass the -l
> (local) option to repack... can anyone confirm that this is the only
> difference?
Yes. And if you look in git-gc, you'll see as to why: it uses the -l flag.
> Also can anybody confirm whether git repack -a -d actually includes in
> the pack also _all_ the "borrowed" objects? I.e. if it is in fact a way
> to convert a repository that borrows objects into one that is
> self-standing?
Yes exactly.
Ciao,
Dscho
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2007-03-06 21:13 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-03-06 16:13 git gc and git repack Sergio Callegari
2007-03-06 21:13 ` Johannes Schindelin
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).