aboutsummaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorJeff Halter <868228+jhalter@users.noreply.github.com>2022-06-05 15:34:37 -0700
committerJeff Halter <868228+jhalter@users.noreply.github.com>2022-06-05 15:34:37 -0700
commite130e0a2142f123d9d6f9351d0758289f010a1bb (patch)
tree2515cf0857aa9b2643b79daf9f3959078e1ee919 /cmd
parent0a92e50b2704c1eb02233c9aa5778d21455d345b (diff)
Add -config flag to client
Diffstat (limited to 'cmd')
-rw-r--r--cmd/mobius-hotline-client/main.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/cmd/mobius-hotline-client/main.go b/cmd/mobius-hotline-client/main.go
index ec6f895..6bc2d58 100644
--- a/cmd/mobius-hotline-client/main.go
+++ b/cmd/mobius-hotline-client/main.go
@@ -21,6 +21,7 @@ func main() {
sigChan := make(chan os.Signal, 1)
signal.Notify(sigChan, syscall.SIGTERM, syscall.SIGINT, os.Interrupt)
+ configDir := flag.String("config", defaultConfigPath(), "Path to config root")
version := flag.Bool("version", false, "print version and exit")
logLevel := flag.String("log-level", "info", "Log level")
logFile := flag.String("log-file", "", "output logs to file")
@@ -70,9 +71,7 @@ func main() {
cancelRoot()
}()
- cfgPath := defaultConfigPath()
-
- client := hotline.NewClient(cfgPath, logger)
+ client := hotline.NewClient(*configDir, logger)
client.DebugBuf = db
client.UI.Start()