From 3302b8f4d9276d0f1c1f3698bc5f6440d5dab5a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Boutemy?= Date: Sat, 28 Apr 2018 09:12:31 +0200 Subject: [PATCH] added details on redirection to a file --- jansi/src/main/java/org/fusesource/jansi/AnsiMain.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/jansi/src/main/java/org/fusesource/jansi/AnsiMain.java b/jansi/src/main/java/org/fusesource/jansi/AnsiMain.java index 673e7029..79a60c47 100644 --- a/jansi/src/main/java/org/fusesource/jansi/AnsiMain.java +++ b/jansi/src/main/java/org/fusesource/jansi/AnsiMain.java @@ -40,10 +40,13 @@ * support natively ANSI escape sequences like any Unix terminal, *
  • on Windows, cmd.exe, PowerShell or Git-cmd terminals should get WINDOWS mode.
  • * - * The results will vary if you play with jansi.passthrough, jansi.strip or + * If stdout is redirected to a file (> out.txt), System.out should switch to STRIP_ANSI. + * Same for stderr redirection (2> err.txt) which should affect System.err mode. + *

    The results will vary if you play with jansi.passthrough, jansi.strip or * jansi.force system property, or if you redirect output to a file. *

    If you have a specific situation that is not covered, please report precise conditions to reproduce * the issue and ideas on how to detect precisely the affected situation. + * @see AnsiConsole */ public class AnsiMain { public static void main(String... args) throws IOException {