Re: [PATCH] pack-objects: turn off bitmaps when skipping objects

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

 



On Fri, Jan 24, 2014 at 12:56:17AM +0100, Vicent Martí wrote:

> On Fri, Jan 24, 2014 at 12:45 AM, Siddharth Agarwal <sid0@xxxxxx> wrote:
> > Yes, we'd prefer to do that too. How do you actually do this, though? I
> > don't see a way to pass `--honor-pack-keep` (shouldn't I pass in its
> > inverse?) down to `git-pack-objects`.
> 
> We run with this patch in production, it may be of use to you:
> https://gist.github.com/vmg/8589317
> 
> In fact, it may be worth upstreaming too. I'll kindly ask peff to do
> it when he has a moment.

I was actually looking at it earlier when I sent this message. The
tricky thing about the patch is that it turns off --honor-pack-keep, but
does _not_ teach git-repack to clean up the .keep file.

Which I think is the right and safe thing to do, as otherwise you might
blow away a pack with .keep, even though you did not just pack its
objects (i.e., because it was written by a fetch or push which did not
yet update the refs). So the safe thing is to actually duplicate those
objects, leave the .keep pack around, and then assume it will get
cleaned up on the next repack.

If you _do_ have a stale .keep file, though, then that stale pack will
hang around forever (presumably with its objects duplicated in the
"real" pack).

So I think the patch is doing the right thing, but I was still figuring
out how to explain it (and I hope I just did). I'll post it with a full
commit message tomorrow.

-Peff
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]