diff options
author | Joey Hess <joeyh@joeyh.name> | 2018-04-26 16:13:05 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2018-04-26 16:13:05 -0400 |
commit | 2fc768ce728fdf183b6176dbf749774f9ce1af06 (patch) | |
tree | 7620dd293c42dfc3a1c1a79b060abad7b0327978 /Logs | |
parent | bea0ad220a68138dc0a43d0c86bb2353ecf92d2c (diff) |
avoid git annex info remote buffering list of keys
This leaves git annex unused --from remote still using loggedKeysFor
and buffering more than ought to be necessary, but I can't see a way to
improve that.
Diffstat (limited to 'Logs')
-rw-r--r-- | Logs/Location.hs | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/Logs/Location.hs b/Logs/Location.hs index 621cca9716..725ce1a075 100644 --- a/Logs/Location.hs +++ b/Logs/Location.hs @@ -27,6 +27,7 @@ module Logs.Location ( finishCheck, loggedKeys, loggedKeysFor, + loggedKeysFor', ) where import Annex.Common @@ -139,10 +140,15 @@ loggedKeys' check = mapMaybe (defercheck <$$> locationLogFileKey) ) {- Finds all keys that have location log information indicating - - they are present for the specified repository. + - they are present in the specified repository. + - + - This does not stream well; use loggedKeysFor' for lazy streaming. -} loggedKeysFor :: UUID -> Annex [Key] -loggedKeysFor u = catMaybes <$> (mapM finishCheck =<< loggedKeys' isthere) +loggedKeysFor u = catMaybes <$> (mapM finishCheck =<< loggedKeysFor' u) + +loggedKeysFor' :: UUID -> Annex [Unchecked Key] +loggedKeysFor' u = loggedKeys' isthere where isthere k = do us <- loggedLocations k |