From 0ab999b988c62b701bde26a8bad2b75da0a7ac43 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 5 Dec 2023 09:46:23 +0000 Subject: cindex: index full (40/64 char) hex blob OIDs This future proofs the index against git auto-abbreviation needing more characters as the repo grows. It'll be useful for joining against inboxes using dfpre. As with emails, we'll continue indexing abbreviated blob OIDs down to 7 hex characters so a SHA-1 git repo will have all abbreviations of the OID from 7-39 hex characters in addition to the 40 character unabbreviated form. --- t/cindex.t | 3 +++ 1 file changed, 3 insertions(+) (limited to 't') diff --git a/t/cindex.t b/t/cindex.t index 0193cf18..716e5984 100644 --- a/t/cindex.t +++ b/t/cindex.t @@ -288,6 +288,9 @@ EOM ++$nr; }, '.'); is $nr, 1, 'iterated through cindices'; + my $oid = 'dba13ed2ddf783ee8118c6a581dbf75305f816a3'; + my $mset = $csrch->mset("dfpost:$oid"); + is $mset->size, 1, 'got result from full OID search'; } done_testing; -- cgit v1.2.3-24-ge0c7