From e1a9f4ae3643af143817d2efd67512d781c8db9c Mon Sep 17 00:00:00 2001 From: "David J. Allen" Date: Tue, 3 Dec 2024 12:51:48 -0700 Subject: [PATCH] fix: changed output to use log instead of fmt --- cmd/root.go | 2 +- cmd/serve.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/root.go b/cmd/root.go index be9659c..1d1997c 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -51,7 +51,7 @@ func initConfig() { if configPath != "" { exists, err := util.PathExists(configPath) if err != nil { - fmt.Printf("failed to load config") + log.Error().Err(err).Str("path", configPath).Msg("failed to load config") os.Exit(1) } else if exists { conf = config.Load(configPath) diff --git a/cmd/serve.go b/cmd/serve.go index 61bfeff..d421538 100644 --- a/cmd/serve.go +++ b/cmd/serve.go @@ -27,7 +27,7 @@ var serveCmd = &cobra.Command{ conf.AccessToken = accessToken } else { if verbose { - fmt.Printf("No token found. Continuing without one...\n") + log.Warn().Msg("No token found. Continuing without one...\n") } } }