always write log, so it's empty if nothing is unused
This commit is contained in:
parent
611018e4bd
commit
ba6727f663
1 changed files with 4 additions and 4 deletions
|
@ -38,13 +38,13 @@ checkUnused :: Annex Bool
|
|||
checkUnused = do
|
||||
showNote "checking for unused data..."
|
||||
unused <- unusedKeys
|
||||
let list = number 1 unused
|
||||
g <- Annex.gitRepo
|
||||
liftIO $ writeFile (annexUnusedLog g) $ unlines $
|
||||
map (\(n, k) -> show n ++ " " ++ show k) list
|
||||
if null unused
|
||||
then return True
|
||||
else do
|
||||
let list = number 1 unused
|
||||
g <- Annex.gitRepo
|
||||
liftIO $ writeFile (annexUnusedLog g) $ unlines $
|
||||
map (\(n, k) -> show n ++ " " ++ show k) list
|
||||
showLongNote $ w list
|
||||
return False
|
||||
where
|
||||
|
|
Loading…
Reference in a new issue