Syroot.ColoredConsole 2.0.2

Prefix Reserved
dotnet add package Syroot.ColoredConsole --version 2.0.2                
NuGet\Install-Package Syroot.ColoredConsole -Version 2.0.2                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Syroot.ColoredConsole" Version="2.0.2" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Syroot.ColoredConsole --version 2.0.2                
#r "nuget: Syroot.ColoredConsole, 2.0.2"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Syroot.ColoredConsole as a Cake Addin
#addin nuget:?package=Syroot.ColoredConsole&version=2.0.2

// Install Syroot.ColoredConsole as a Cake Tool
#tool nuget:?package=Syroot.ColoredConsole&version=2.0.2                

A small one-class-library allowing you to quickly interleave colors with your ColorConsole.Write and ColorConsole.WriteLine commands to render them in full color with one call. Requires VT support of Windows 10.

using System.Drawing;
using Syroot.ColoredConsole;

class Program
{
    static void Main()
    {
        // Interleave argument list with System.Drawing.Color instances to color following text.
        ColorConsole.WriteLine(Color.Red, "This is red! ", Color.Green, "This is green!");

        // Return value is the text without any color or VT commands to log it away elsewhere.
        string plainText = ColorConsole.WriteLine("Normal color. ", Color.Magenta, "Magenta!");
        System.Diagnostics.Debug.WriteLine(plainText);
    }
}

Unsupported systems will simply write uncolored text.

Product Compatible and additional computed target framework versions.
.NET net5.0 is compatible.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net5.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2.0.2 561 5/19/2022
2.0.1 417 10/2/2021
1.0.1 586 7/11/2020
1.0.0 463 7/9/2020

Allow use in Windows services or other scenarioes where the console is redirected.