From ea88db811f23e9ed5388d64c1b891a3496c909d9 Mon Sep 17 00:00:00 2001 From: raven Date: Mon, 9 Feb 2026 13:36:21 -0600 Subject: allow specifying server address at command line --- client/main.go | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/client/main.go b/client/main.go index 707cf7e..e4a9f6b 100644 --- a/client/main.go +++ b/client/main.go @@ -3,6 +3,7 @@ package main import ( "citrons.xyz/talk/tui" "citrons.xyz/talk/client/clipboard" + "flag" "time" "fmt" "os" @@ -11,6 +12,12 @@ import ( var globalApp *application func main() { + flag.Parse() + address := flag.Arg(0) + if address == "" { + address = "talk.citrons.xyz:27508" + } + go clipboard.DiscoverCommand() err := tui.Start() @@ -23,7 +30,7 @@ func main() { fmt.Println("bye!") }() - globalApp = newApplication("alt.mondecitronne.com:27508") + globalApp = newApplication(address) go globalApp.RunClient() defer globalApp.Stop() -- cgit v1.2.3