Thread (1 message) 1 message, 1 author, 2016-06-15

Re: [PATCH] git-count-objects --all support

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:42:17

Junio C Hamano [off-list ref] writes:
The point of counting objects is to see if it is time to repack,
so the warning is something I am quite hesitant to accept, even
with a suppression option.  The other way around is probably OK
("please warn me if I have packs"), but feels somewhat pointless.

The --all option might be a welcome addition, though.
I think your patch counts the same object twice if it is packed
in more than one packs and/or it has a loose copy _and_ also in
a pack.  If it is a good thing or not is totally up to the
reason why we are counting.

We might be better off if we did this kind of additions by
building on fsck-objects.  For example, you could give a --stat
option that might say something like this:

	$ git fsck-objects --full --stat
        commit	 2488
        tree    43343
        blob   212234
        total  258065
	packed 184382
	loose   78115
        dups     4432

where "dups" is number of duplicated copies --- an object packed
in more than two packs, or appearing in a pack and also having a
loose copy.  I dunno.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help