pack-objects: extend --local to mean ignore non-local loose objects too
With this patch, --local means pack only local objects that are not already packed. Additionally, this fixes t7700 testing whether loose objects in an alternate object database are repacked. Signed-off-by: Brandon Casey <drafnel@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
0f4dc14ac4
commit
daae062595
@ -691,6 +691,9 @@ static int add_object_entry(const unsigned char *sha1, enum object_type type,
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (!exclude && local && has_loose_object_nonlocal(sha1))
|
||||
return 0;
|
||||
|
||||
for (p = packed_git; p; p = p->next) {
|
||||
off_t offset = find_pack_entry_one(sha1, p);
|
||||
if (offset) {
|
||||
|
Reference in New Issue
Block a user