diff --git a/cmd/root.go b/cmd/root.go index 5f9a119..a4b03c4 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -58,8 +58,8 @@ func setLogLevel(verbose bool) int { // Execute adds all child commands to the root command and sets flags appropriately. // This is called by main.main(). It only needs to happen once to the rootCmd. func Execute() { - err := rootCmd.Execute() - if err != nil { + if err := rootCmd.Execute(); err != nil { + log.Error(err.Error()) os.Exit(1) } }