Re: [PATCH 2/6] sha1-lookup: handle duplicate keys with GIT_USE_LOOKUP
- From
Jeff King <peff@peff.net>
- Date
- Aug 23, 2013, 18:56 UTC
- Message-ID
- <20130823185618.GD30130@sigill.intra.peff.net>
- In-Reply-To
- <alpine.LFD.2.03.1308231451030.14472@syhkavp.arg>
On Fri, Aug 23, 2013 at 02:54:19PM -0400, Nicolas Pitre wrote:
Show 16 quoted lines
> On Fri, 23 Aug 2013, Jeff King wrote: > > > Making the deltas was considerably less elegant, since we cannot provoke > > pack-objects to pick arbitrary deltas (and it will not even try to delta > > tiny objects, anyway, which would bloat our samples). I ended up with > > the horrible patch below. We _could_ clean it up (error-checking? Who > > needs it?) and make it a debug-and-testing-only option for pack-objects, > > but I just didn't think the grossness was worth it. Still, it's probably > > worth documenting here on the list in case somebody else ever needs to > > add new samples to lib-pack.sh. > > Maybe using test-delta (from test-delta.c) would have helped here? > > In any case, if something needs to be permanently added into the code to > help in the creation of test objects, I think test-delta.c is a far > better place than pack-objects.c.
*forehead palm*
I didn't even know we had test-delta. Yes, that is obviously a way better place (I initially looked at pack-objects because it has the helpers to do compression and the type/size header properly).
-Peff