Skip to content

Commit

Permalink
Return an error if the run-once has any errors (#88)
Browse files Browse the repository at this point in the history
  • Loading branch information
sudermanjr authored Mar 17, 2023
1 parent bd0cf07 commit e79b7e6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pkg/app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -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
}

Expand Down

0 comments on commit e79b7e6

Please sign in to comment.