namespace FinalFactory.Rendezvous.TestClient; public static class Program { public static async Task Main(string[] args) { using CancellationTokenSource shutdown = new(); ConsoleCancelEventHandler cancelHandler = (_, eventArgs) => { eventArgs.Cancel = true; shutdown.Cancel(); }; Console.CancelKeyPress += cancelHandler; try { TestClientApplication application = new(new RendezvousCommandRunner()); return await application.RunAsync( args, Console.In, Console.Out, Console.Error, shutdown.Token).ConfigureAwait(false); } finally { Console.CancelKeyPress -= cancelHandler; } } }