1
0

feat: make cursor visible on exit

This commit is contained in:
2026-03-12 00:49:12 +01:00
parent ef30a2254b
commit fe006a5256

View File

@@ -1,15 +1,16 @@
using Spectre.Console; using Spectre.Console;
namespace AnchorCli.Commands; namespace AnchorCli.Commands;
public class ExitCommand : ICommand public class ExitCommand : ICommand
{ {
public string Name => "exit"; public string Name => "exit";
public string Description => "Exit the application"; public string Description => "Exit the application";
public Task ExecuteAsync(string[] args, CancellationToken ct) public Task ExecuteAsync(string[] args, CancellationToken ct)
{ {
AnsiConsole.MarkupLine("[green]Goodbye![/]"); AnsiConsole.MarkupLine("[green]Goodbye![/]");
Environment.Exit(0); Console.CursorVisible = true;
return Task.CompletedTask; Environment.Exit(0);
} return Task.CompletedTask;
} }
}