From f985c58d8e95026f4d64364b29d01df1de499928 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sat, 17 Aug 2024 14:58:36 -0400 Subject: [PATCH] consistently don't show sizes of empty repositories This used to be the case, and when matching options are used, that code path still omits them, so also omit them in the getRepoSize code path. --- Command/Info.hs | 2 +- doc/todo/git-annex_proxies.mdwn | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Command/Info.hs b/Command/Info.hs index 3f120c1920..0e75c84245 100644 --- a/Command/Info.hs +++ b/Command/Info.hs @@ -654,7 +654,7 @@ cachedAllRepoData = do usereposizes s = do sizemap <- lift $ getRepoSizes True deadset <- lift $ S.fromList <$> trustGet DeadTrusted - let sizemap' = M.withoutKeys sizemap deadset + let sizemap' = M.filter (> 0) $ M.withoutKeys sizemap deadset lift $ unlessM (null <$> getUnmergedRefs) warnunmerged return $ s diff --git a/doc/todo/git-annex_proxies.mdwn b/doc/todo/git-annex_proxies.mdwn index 3c7b8fa8d5..21fdc8fd99 100644 --- a/doc/todo/git-annex_proxies.mdwn +++ b/doc/todo/git-annex_proxies.mdwn @@ -81,6 +81,11 @@ Planned schedule of work: Also note that "fullybalanced=foo:2" is not currently actually implemented! +* `git-annex info` in the limitedcalc path in cachedAllRepoData + double-counts redundant information from the journal due to using + overLocationLogs. In the other path it does not, and this should be fixed + for consistency and correctness. + * `git-annex info` can use maxsize to display how full repositories are * implement size-based balancing, so all balanced repositories are around