From e79b7e68db3c8dd51bde3ae8cc2d3c2b30e6dd4f Mon Sep 17 00:00:00 2001 From: Andrew Suderman Date: Fri, 17 Mar 2023 14:00:19 -0600 Subject: [PATCH] Return an error if the run-once has any errors (#88) --- pkg/app/app.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkg/app/app.go b/pkg/app/app.go index 708f96b..993f0cb 100644 --- a/pkg/app/app.go +++ b/pkg/app/app.go @@ -167,6 +167,10 @@ func (a *App) RunOnce() error { go a.updateCircleCIInstance(project, &wg) } wg.Wait() + errCount := getMetricValue(a.Metrics.totalErrorCount) + if errCount > 0 { + return fmt.Errorf("there were errors during during the run. see the logs for more details") + } return nil }