Files
spectre.console/src/Tests/Spectre.Console.Cli.Tests/Data/Commands/VersionCommand.cs
Patrik Svensson 42fd801876 Preparations for the 1.0 release
* Less cluttered solution layout.
* Move examples to a repository of its own.
* Move Roslyn analyzer to a repository of its own.
* Enable central package management.
* Clean up csproj files.
* Add README file to NuGet packages.
2024-08-06 15:38:28 +02:00

19 lines
448 B
C#

namespace Spectre.Console.Tests.Data;
public sealed class VersionCommand : Command<VersionSettings>
{
private readonly IAnsiConsole _console;
public VersionCommand(IAnsiConsole console)
{
_console = console;
}
public override int Execute(CommandContext context, VersionSettings settings)
{
_console.WriteLine($"VersionCommand ran, Version: {settings.Version ?? string.Empty}");
return 0;
}
}