Skip to content

Commit c90fdd3

Browse files
committed
Config search now looks into ARDUINO_DIRECTORIES_DATA env too
1 parent 1b2ebdc commit c90fdd3

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

internal/cli/configuration/configuration.go

+6
Original file line numberDiff line numberDiff line change
@@ -109,5 +109,11 @@ func FindConfigFileInArgsFallbackOnEnv(args []string) string {
109109
if p, ok := os.LookupEnv("ARDUINO_CONFIG_FILE"); ok {
110110
return p
111111
}
112+
if p, ok := os.LookupEnv("ARDUINO_DIRECTORIES_DATA"); ok {
113+
return filepath.Join(p, "arduino-cli.yaml")
114+
}
115+
if p, ok := os.LookupEnv("ARDUINO_DATA_DIR"); ok {
116+
return filepath.Join(p, "arduino-cli.yaml")
117+
}
112118
return filepath.Join(getDefaultArduinoDataDir(), "arduino-cli.yaml")
113119
}

0 commit comments

Comments
 (0)