From 0761409497041c752086b9aded08cf9e32e30fd2 Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Sun, 28 Sep 2025 17:30:44 +0300 Subject: Add --config flag support across CLI, LSP, and tmux tools --- cmd/hexai-lsp/main.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'cmd/hexai-lsp/main.go') diff --git a/cmd/hexai-lsp/main.go b/cmd/hexai-lsp/main.go index f2cad6d..9764f0b 100644 --- a/cmd/hexai-lsp/main.go +++ b/cmd/hexai-lsp/main.go @@ -5,6 +5,7 @@ import ( "flag" "log" "os" + "strings" "codeberg.org/snonux/hexai/internal" "codeberg.org/snonux/hexai/internal/hexailsp" @@ -12,6 +13,7 @@ import ( func main() { logPath := flag.String("log", "/tmp/hexai-lsp.log", "path to log file (optional)") + configPath := flag.String("config", "", "path to config file") showVersion := flag.Bool("version", false, "print version and exit") flag.Parse() if *showVersion { @@ -19,7 +21,8 @@ func main() { return } - if err := hexailsp.Run(*logPath, os.Stdin, os.Stdout, os.Stderr); err != nil { + path := strings.TrimSpace(*configPath) + if err := hexailsp.RunWithConfig(*logPath, path, os.Stdin, os.Stdout, os.Stderr); err != nil { log.Fatalf("server error: %v", err) } } -- cgit v1.2.3