forked from TrueCloudLab/restic
check: hide message about additional files if error in repo
The message says "[...] addition files were found [...]. This is non-critical [...]". Unless users are highly experienced with restic, it's hard to correctly interpret what "This" refers to. Thus, just hide the message if there is a real problem.
This commit is contained in:
parent
b1250eead9
commit
1671a3fe2e
1 changed files with 2 additions and 1 deletions
|
@ -296,7 +296,8 @@ func runCheck(ctx context.Context, opts CheckOptions, gopts GlobalOptions, args
|
|||
}
|
||||
}
|
||||
|
||||
if orphanedPacks > 0 {
|
||||
if orphanedPacks > 0 && !errorsFound {
|
||||
// hide notice if repository is damaged
|
||||
printer.P("%d additional files were found in the repo, which likely contain duplicate data.\nThis is non-critical, you can run `restic prune` to correct this.\n", orphanedPacks)
|
||||
}
|
||||
if ctx.Err() != nil {
|
||||
|
|
Loading…
Reference in a new issue