bring back display of keys
in fsck -q, that's the only way to know what file it means
This commit is contained in:
parent
ee2e94f087
commit
3cb5cb6bf6
1 changed files with 11 additions and 9 deletions
|
@ -184,22 +184,24 @@ checkKeyNumCopies key numcopies = do
|
||||||
if present < needed
|
if present < needed
|
||||||
then do
|
then do
|
||||||
ppuuids <- prettyPrintUUIDs untrustedlocations
|
ppuuids <- prettyPrintUUIDs untrustedlocations
|
||||||
warning $ missingNote present needed ppuuids
|
warning $ missingNote (show key) present needed ppuuids
|
||||||
return False
|
return False
|
||||||
else return True
|
else return True
|
||||||
where
|
where
|
||||||
|
|
||||||
missingNote :: Int -> Int -> String -> String
|
missingNote :: String -> Int -> Int -> String -> String
|
||||||
missingNote 0 _ [] =
|
missingNote file 0 _ [] =
|
||||||
"** No known copies of this file exist!"
|
"** No known copies of " ++ file ++ " exist!"
|
||||||
missingNote 0 _ untrusted =
|
missingNote file 0 _ untrusted =
|
||||||
"Only these untrusted locations may have copies of this file!" ++
|
"Only these untrusted locations may have copies of " ++ file ++
|
||||||
|
"\n-- they could lose it at any time!" ++
|
||||||
"\n" ++ untrusted ++
|
"\n" ++ untrusted ++
|
||||||
"Back it up to trusted locations with git-annex copy."
|
"Back it up to trusted locations with git-annex copy."
|
||||||
missingNote present needed [] =
|
missingNote file present needed [] =
|
||||||
"Only " ++ show present ++ " of " ++ show needed ++
|
"Only " ++ show present ++ " of " ++ show needed ++
|
||||||
" trustworthy copies of this file exist." ++
|
" trustworthy copies of " ++ file ++ " exist." ++
|
||||||
"\nBack it up with git-annex copy."
|
"\nBack it up with git-annex copy."
|
||||||
missingNote present needed untrusted = missingNote present needed [] ++
|
missingNote file present needed untrusted =
|
||||||
|
missingNote file present needed [] ++
|
||||||
"\nThe following untrusted copies may also exist: " ++
|
"\nThe following untrusted copies may also exist: " ++
|
||||||
"\n" ++ untrusted
|
"\n" ++ untrusted
|
||||||
|
|
Loading…
Reference in a new issue