Files
firezone/rust/tests
Thomas Eizinger 9e9599952f refactor(gui-client): streamline command handling (#9153)
The way the GUI client currently handles the commands and flags provided
via the CLI is somewhat confusing. There are various helper functions
that get called from the same place. We duplicate setup like the `tokio`
runtime in multiple places and the also loggers get initialised all over
the place.

To streamline this, we move global setup like `tokio` and telemetry to
the top-layer. From there, we delegate to a `try_main` function which
handles the various CLI commands. The default path from here is to run
the gui by delegating to the `gui` module. If not, we bail out early.

This structure is significantly easier to understand and provides error
and telemetry handling in a single place.
2025-05-16 01:20:46 +00:00
..