From c207432a87e9df1297c827ad1864e8f3b960f1fa Mon Sep 17 00:00:00 2001 From: Evgenii Novozhilov Date: Tue, 17 Dec 2024 14:33:26 +0200 Subject: [PATCH] Do not append `\n` for PROCESS since that output has all of the delimiters and can be chunked not per line. (#7146) (cherry picked from commit f5f8f24a8b84726b7b1606ba3d7b16b072da09a7) --- .../idea/blaze/base/toolwindow/ConsoleView.java | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/base/src/com/google/idea/blaze/base/toolwindow/ConsoleView.java b/base/src/com/google/idea/blaze/base/toolwindow/ConsoleView.java index 30ecf184f17..d14a06e1c9a 100644 --- a/base/src/com/google/idea/blaze/base/toolwindow/ConsoleView.java +++ b/base/src/com/google/idea/blaze/base/toolwindow/ConsoleView.java @@ -237,19 +237,17 @@ void println(PrintOutput output) { } private void println(String text, OutputType outputType) { - if (outputType == OutputType.PROCESS) { - text = text.stripTrailing(); - } - ansiEscapeDecoder.escapeText( text, outputType == OutputType.ERROR ? ProcessOutputTypes.STDERR : ProcessOutputTypes.STDOUT, (t, k) -> consoleView.print(t, ConsoleViewContentType.getConsoleViewType(k))); - consoleView.print( - "\n", - outputType == OutputType.ERROR - ? ConsoleViewContentType.ERROR_OUTPUT - : ConsoleViewContentType.NORMAL_OUTPUT); + if (outputType != OutputType.PROCESS) { + consoleView.print( + "\n", + outputType == OutputType.ERROR + ? ConsoleViewContentType.ERROR_OUTPUT + : ConsoleViewContentType.NORMAL_OUTPUT); + } } public void printHyperlink(String text, HyperlinkInfo hyperlinkInfo) {