gc.sh: do not always ignore non pack-<40hex>*.pack files
commit350eaf81f9215751a1858e045c267cbe034b1a0c
authorKyle J. McKay <mackyle@gmail.com>
Sat, 30 Dec 2017 23:02:16 +0000 (30 15:02 -0800)
committerKyle J. McKay <mackyle@gmail.com>
Sat, 30 Dec 2017 23:02:16 +0000 (30 15:02 -0800)
tree211e9146ca7b5c6ae813d44249392d2dd61a5de5
parent6a11e864b5832624c2e2de9747159de6a74b97dd
gc.sh: do not always ignore non pack-<40hex>*.pack files

When doing a full garbage collection (or even possibly a "mini")
there exist brief moments when a pack might exist with a name not
matching pack-<40hex>*.pack.

This should only happen when combining packs and replacing a
same-named pack and the old pack briefly takes on a
"oldpack-<40hex>*.pack" name during the replace.

However, there could be other *.pack files present in the
repository for some unknown reason.

And we need to avoild the extremely remote possibility of oldpack-*.pack
files accumulating from interruptions of --replace operations anyway.

Stop ignoring the other names (except for the pre-auto-gc ones) and
handle them just like any other packs, mostly.

They continue to be ignored by "mini" gc activity because there
just shouldn't be any in the first place, but if there are then a
full gc will now address them.

Signed-off-by: Kyle J. McKay <mackyle@gmail.com>
jobd/gc.sh