Welcome!
Spectre.Console is a .NET
library that makes it easier
to create beautiful console applications.
Spectre.Console.AnsiConsole
- Easily output text with different colors and even styles such as bold, italic and blinking with a Rich inspired markup language.
- Supports
3
/4
/8
/24
-bit colors in the terminal with auto-detection of the current terminal's capabilities. - Render complex widgets such as tables, trees, and even ASCII images.
- Display progress for long running tasks with live displays of progress and status controls.
- Prompt user input with strongly typed text input or via single-item select and multiple item select controls.
- Format .NET exceptions with custom color coded themes and styles.
Spectre.Console.AnsiConsole has been heavily inspired by the excellent Rich library for Python written by Will McGugan.
Spectre.Console.Cli
- Create strongly typed settings and commands for parsing
args[]
to create complex command line applications likegit
,gh
, ordotnet
Spectre.Console.Testing
Spectre.Console has been developed with unit testing in mind. The Spectre.Console library itself is covered by an extensive test suite, project maintainers require test coverage for all new commits, and the same extension points and test harnesses used internally for testing are available to you.
The Unit Testing page provides instructions for testing a Spectre.Console application.
Examples
The Spectre.Console examples repository contains many other examples.