A very simple class library to aid in printing coloured output to the console.
The public API is small. Simply create an instance of
using System; using ColorConsole; ... var console = new ConsoleWriter();
and invoke the method of your choice:
console.Write("Be seeing you!", ConsoleColor.Yellow);
Ideally, you should rely on the
This interface can then be used in conjunction with your favourite DI framework.
The main motivation was to reduce the typical boilerplate code involved to output colored text to the console. Quite often, you would see console applications defining/duplicating this behaviour in their own assembly each time it was required.
The easiest way to install
ColorConsole is via Paket or Nuget.
Assuming your project has
mono .paket/paket.exe add nuget ColorConsole
.paket/paket.exe add nuget ColorConsole
Acquire the source code.
Or if you don't have access to a bash env:
Logo credit to deadletterdesign