This topic walks you through the steps to follow to have colours for log levels, and errors analysis in the Harness console in NextGen
Use case :
Is it possible to have the Harness console show colours when you run Junit tests via maven same as in, say IntelliJ editor or terminal (iTerm)?
echo "\033[35mSkipping building JARs for optimization master branch, just downloading them from Artifactory!\033[0m"
It would be helpful if we could have colours for log levels and error analysis in the Harness console.
Steps to achieve this use case:
Harness logs viewer uses ANSI escape code. This is the same standard used by bash and other terminal software.
We should be able to retain colours if the tool emits coloured output. Sample screenshot from Harness pipeline log:
You can achieve this with No config changes. Just use any binary/tool which is expected to emit coloured logs.
For example, the maven parameter
-Dstyle.color=alwayswill help you to add colours for log levels and error analysis in the Harness console.
These are the steps we need to follow to have colours for log levels and error analysis in the Harness console in NextGen.