From f9ac7b7f539083db89c9900e87faeba7acd7bb66 Mon Sep 17 00:00:00 2001 From: Denis Kirillov Date: Tue, 3 Sep 2024 15:39:03 +0300 Subject: [PATCH] Use stdout as command output Signed-off-by: Denis Kirillov --- modules/root.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/modules/root.go b/modules/root.go index e6edf5a..d862bd5 100644 --- a/modules/root.go +++ b/modules/root.go @@ -52,6 +52,9 @@ const configFlag = "config" func init() { cobra.EnableTraverseRunHooks = true + + rootCmd.SetOut(os.Stdout) + rootCmd.PersistentFlags().StringP(configFlag, "c", "", "Path to config file") cobra.AddTemplateFunc("runtimeVersion", runtime.Version)