8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
arduino-cli.yaml
~/.arduino15
1 parent e7b8550 commit 9d859f4Copy full SHA for 9d859f4
main.go
@@ -9,6 +9,8 @@ import (
9
"os"
10
"os/exec"
11
"os/signal"
12
+ "os/user"
13
+ "path"
14
15
"github.com/arduino/arduino-language-server/ls"
16
"github.com/arduino/arduino-language-server/streams"
@@ -75,6 +77,15 @@ func main() {
75
77
log.Fatal("ArduinoCLI daemon address and instance number must be set.")
76
78
}
79
} else {
80
+ if *cliConfigPath == "" {
81
+ if user, _ := user.Current(); user != nil {
82
+ candidate := path.Join(user.HomeDir, ".arduino15/arduino-cli.yaml")
83
+ if _, err := os.Stat(candidate); err == nil {
84
+ *cliConfigPath = candidate
85
+ log.Printf("ArduinoCLI config file found at %s\n", candidate)
86
+ }
87
88
89
if *cliConfigPath == "" {
90
log.Fatal("Path to ArduinoCLI config file must be set.")
91
0 commit comments