treat dead repos as 0 size
authorJoey Hess <joeyh@joeyh.name>
Mon, 13 Nov 2023 18:46:51 +0000 (14:46 -0400)
committerJoey Hess <joeyh@joeyh.name>
Mon, 13 Nov 2023 19:05:48 +0000 (15:05 -0400)
commit2ab11fe06ec386535ef9580d21354502c74f2045
tree8c4179d954786521ce766e0e6d973882dd79b05b
parent38b9ebc5fd15188beddf637aa355238afd1a047d
treat dead repos as 0 size

With this, git annex log --totalsizes can be compared with
git-annex info's "combined annex size of all repositories"
to double-check it works correctly.

In my sound repo, the two match.

In my big repo, the two report slightly different sizes,
with the former being 1.3 gb smaller than the latter.
I don't know the reason for this disreprency. Given the 30+tb size of
the repo, it's a small difference.

It seems possible that a bug in an old version of git-annex could
explain it. Eg, if an old git-annex lost a line when updating trust.log
or a location log in a merge, git-annex info would see only what it
replaced it with, while git-annex log will see the previous value as
well.

Sponsored-by: Leon Schuermann on Patreon
Command/Log.hs