From b1250eead9bb6f69e618993509ef1964bd3e10ce Mon Sep 17 00:00:00 2001 From: Michael Eischer Date: Sun, 30 Jun 2024 10:55:44 +0200 Subject: [PATCH] check: mark s3legacy layout and legacy indexes are error --- cmd/restic/cmd_check.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cmd/restic/cmd_check.go b/cmd/restic/cmd_check.go index cccb1986e..1a27ed6ea 100644 --- a/cmd/restic/cmd_check.go +++ b/cmd/restic/cmd_check.go @@ -264,7 +264,7 @@ func runCheck(ctx context.Context, opts CheckOptions, gopts GlobalOptions, args term.Print("Duplicate packs are non-critical, you can run `restic repair index' to correct this.\n") } if suggestLegacyIndexRebuild { - printer.E("Found indexes using the legacy format, you must run `restic repair index' to correct this.\n") + printer.E("error: Found indexes using the legacy format, you must run `restic repair index' to correct this.\n") } if mixedFound { term.Print("Mixed packs with tree and data blobs are non-critical, you can run `restic prune` to correct this.\n") @@ -288,7 +288,8 @@ func runCheck(ctx context.Context, opts CheckOptions, gopts GlobalOptions, args orphanedPacks++ printer.P("%v\n", err) } else if err == checker.ErrLegacyLayout { - printer.P("repository still uses the S3 legacy layout\nPlease run `restic migrate s3legacy` to correct this.\n") + errorsFound = true + printer.E("error: repository still uses the S3 legacy layout\nYou must run `restic migrate s3legacy` to correct this.\n") } else { errorsFound = true printer.E("%v\n", err)