Skip to content

Commit

Permalink
Fix #150 (#157)
Browse files Browse the repository at this point in the history
  • Loading branch information
naegelejd authored May 28, 2024
1 parent ed63c58 commit a82aa22
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions tooling/internal/cmd/generatecommand.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ func newGenerateCommand() *cobra.Command {
if err != nil {
// avoiding returning the error here because
// cobra prefixes the error with "Error: "
fmt.Fprintln(os.Stderr, err)
log.Error().Msg(err.Error())
os.Exit(1)
}

Expand Down Expand Up @@ -139,11 +139,10 @@ func generateInWatchMode() []string {
screen.Clear()
screen.MoveTopLeft()

fmt.Printf("Validated model package '%s' at %v.\n\n", packageInfo.Namespace, time.Now().Format("15:04:05"))

if err != nil {
fmt.Println(err)
log.Error().Msg(err.Error())
} else {
fmt.Printf("Validated model package '%s' at %v.\n\n", packageInfo.Namespace, time.Now().Format("15:04:05"))
for _, warning := range warnings {
log.Warn().Msg(warning)
}
Expand Down

0 comments on commit a82aa22

Please sign in to comment.