From 52750bd6158d50faee41cffa1a4840ba7cdb417f Mon Sep 17 00:00:00 2001 From: Andre Duffeck Date: Tue, 8 Aug 2023 13:12:03 +0200 Subject: [PATCH] Fail on errors (#6986) * Return an error when something went wrong * Add changelog --- changelog/unreleased/add-rebuild-jsoncs3-index-command.md | 1 + ocis/pkg/command/migrate.go | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/changelog/unreleased/add-rebuild-jsoncs3-index-command.md b/changelog/unreleased/add-rebuild-jsoncs3-index-command.md index 6998c9a1d..1e05c2a7e 100644 --- a/changelog/unreleased/add-rebuild-jsoncs3-index-command.md +++ b/changelog/unreleased/add-rebuild-jsoncs3-index-command.md @@ -2,4 +2,5 @@ Enhancement: Add command for rebuilding the jsoncs3 share manager indexes We added a command for rebuilding the jsoncs3 share manager indexes. +https://github.com/owncloud/ocis/pull/6986 https://github.com/owncloud/ocis/pull/6971 diff --git a/ocis/pkg/command/migrate.go b/ocis/pkg/command/migrate.go index f978381a2..349aa48bf 100644 --- a/ocis/pkg/command/migrate.go +++ b/ocis/pkg/command/migrate.go @@ -187,7 +187,7 @@ func RebuildJSONCS3Indexes(cfg *config.Config) *cli.Command { fmt.Printf("done\n") } if errorsOccured { - fmt.Printf("There were errors. Please review the logs.") + return errors.New("There were errors. Please review the logs or try again.") } return nil