From 652429377b99085d686d6b907c2f550c304e6b98 Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Mon, 19 May 2025 15:43:14 -0400 Subject: sync --- cmd/root.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'cmd') diff --git a/cmd/root.go b/cmd/root.go index ab102afe6..81083ef72 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -182,6 +182,18 @@ to assist developers in writing, debugging, and understanding code directly from } }() + evts, err := app.Client.Event(ctx) + if err != nil { + slog.Error("Failed to subscribe to events", "error", err) + return err + } + + go func() { + for item := range evts { + program.Send(item) + } + }() + // Cleanup function for when the program exits cleanup := func() { // Cancel subscriptions first -- cgit v1.2.3