Skip to content

Commit 1754f08

Browse files
authored
return a non-zero exit code on errors (#67)
1 parent fdc44d0 commit 1754f08

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

cmd/tcld/fx.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,10 @@ func fxOptions() fx.Option {
3434
if err != nil {
3535
fmt.Fprintf(os.Stderr, "%s\n", err.Error())
3636
}
37-
return shutdowner.Shutdown()
37+
if shutdownErr := shutdowner.Shutdown(); shutdownErr != nil {
38+
fmt.Fprintf(os.Stderr, "failed to shutdown app: %s\n", shutdownErr.Error())
39+
}
40+
return err
3841
}),
3942
fx.NopLogger,
4043
)

0 commit comments

Comments
 (0)