fusesource / jansi

Jansi is a small java library that allows you to use ANSI escape sequences to format your console output which works even on windows.
http://fusesource.github.io/jansi/
Apache License 2.0
1.1k stars 139 forks source link

Not calling AnsiConsole.systemInstall() makes a difference under Windows CMD.exe console #281

Open ceki opened 5 months ago

ceki commented 5 months ago

The logback project got a puzzling report recently which might be of interest here.

The wrapWithJansi method in ConsoleAppender supports both Jansi 1.x and 2.x.

However, it does so without calling AnsiConsole.systemInstall().

Windows CMD terminal and Jansi 1.18, calling AnsiConsole.wrapSystemOut(...) seems to suffice even if AnsiConsole.systemInstall() is not called.

Windows CMD terminal and Jansi 2.4, calling AnsiConsole.out() seems to be insufficient (with a missing AnsiConsole.systemInstall() invocation).

My question is whether calling AnsiConsole.systemInstall() is mandatory in Jansi 2.x ?