@VisibleForTesting
  static boolean isRichConsole(ConsoleOutput consoleOutput, HttpTraceLevel httpTraceLevel) {
    if (httpTraceLevel != HttpTraceLevel.off) {
      return false;
    }

    switch (consoleOutput) {
      case plain:
        return false;
      case auto:
        // Enables progress footer when ANSI is supported (Windows or TERM not 'dumb').
        return System.getProperty("os.name").startsWith("windows")
            || (System.console() != null && !"dumb".equals(System.getenv("TERM")));
      case rich:
      default:
        return true;
    }
  }
Create a new logger for the CLI.

@param verbosity the configure verbosity
@param httpTraceLevel the log level for http trace
@param consoleOutput the configured consoleOutput format
@param stdout the writer to store stdout
@param stderr the writer to store stderr
@param executor a {@link SingleThreadedExecutor} to ensure that all messages are logged in a
    sequential, deterministic order
@return a new ConsoleLogger instance
jib-cli/src/main/java/com/google/cloud/tools/jib/cli/logging/CliLogger.java