From e9f7af749b9866033644d42c64d667a0845c5a7b Mon Sep 17 00:00:00 2001 From: Matt Calhoun Date: Tue, 11 Feb 2025 15:32:03 -0500 Subject: [PATCH 1/2] create logging defaults --- pkg/config/config.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkg/config/config.go b/pkg/config/config.go index 011c321c3b..f6f10a0d50 100644 --- a/pkg/config/config.go +++ b/pkg/config/config.go @@ -134,6 +134,9 @@ func InitCliConfig(configAndStacksInfo schema.ConfigAndStacksInfo, processStacks v.SetDefault("components.terraform.append_user_agent", fmt.Sprintf("Atmos/%s (Cloud Posse; +https://atmos.tools)", version.Version)) v.SetDefault("settings.inject_github_token", true) + v.SetDefault("logs.file", "/dev/stderr") + v.SetDefault("logs.level", "Info") + // Process config in system folder configFilePath1 := "" @@ -377,11 +380,13 @@ func processConfigFile( path string, v *viper.Viper, ) (bool, error) { + // Check if the config file exists configPath, fileExists := u.SearchConfigFile(path) if !fileExists { return false, nil } + reader, err := os.Open(configPath) if err != nil { return false, err From 4b9adb4077fc0e17739cc1afba029d78e504ce45 Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Tue, 11 Feb 2025 20:34:36 +0000 Subject: [PATCH 2/2] [autofix.ci] apply automated fixes --- pkg/config/config.go | 1 - 1 file changed, 1 deletion(-) diff --git a/pkg/config/config.go b/pkg/config/config.go index f6f10a0d50..868e81cd44 100644 --- a/pkg/config/config.go +++ b/pkg/config/config.go @@ -380,7 +380,6 @@ func processConfigFile( path string, v *viper.Viper, ) (bool, error) { - // Check if the config file exists configPath, fileExists := u.SearchConfigFile(path) if !fileExists {