https://github.com/nikiforovall/cli-with-spectre-console
An example CLI application based on Spectre.Console
https://github.com/nikiforovall/cli-with-spectre-console
cli dotnet spectre
Last synced: 7 months ago
JSON representation
An example CLI application based on Spectre.Console
- Host: GitHub
- URL: https://github.com/nikiforovall/cli-with-spectre-console
- Owner: NikiforovAll
- Created: 2022-01-22T09:18:47.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2022-01-22T16:23:16.000Z (over 3 years ago)
- Last Synced: 2025-03-16T18:42:14.737Z (7 months ago)
- Topics: cli, dotnet, spectre
- Language: C#
- Homepage: https://nikiforovall.github.io/dotnet/2022/01/22/building-console-application-with-spectre-console.html
- Size: 19.5 KB
- Stars: 11
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# .NET Bots Gallery with Spectre.Console
`Spectre.Console` provides application model to bind `args[]` to git-style commands.
```csharp
var app = new CommandApp();app.Configure(c =>
{
c.AddCommand("scrape");
c.AddCommand("list");
c.AddCommand("download")
.WithExample(new[] {"download", "--random"});
});await app.RunAsync(args);
```## Demo
`dotnet run -- -h`

`dotnet run -- scrape`

`dotnet run -- list`
➕🎉

`dotnet run -- download`
➕🎉

## Reference
*
*
* Known issues