Search code examples
intellij-idea

Is it possible to have clickable class names in console output in IntelliJ?


When you run a server inside of IntelliJ you can see the console output in the window at the bottom of the screen.

Is there any way to format the output so that IntelliJ will recognize class names and make them clickable? Then when I see a class name in the server output I could click on it and go straight there.

Thanks :)


Solution

  • There is. Taken from online help http://www.jetbrains.com/idea/webhelp/setting-log-options.html

    If you are using third-party logging tools, you might want to make the message's output, that mimics a standard linkage to the source code as for stacktrace line (at .(:)). For that, you should add specific Conversion Pattern to your log.xml configuration file. For example, in a log4j Conversion Pattern this would be

    <param name="ConversionPattern" value="%-5p - [%-80m] - at %c.%M(%F:%L)%n"/>
    

    However the produces output is quite ugly with fully qualified names, method names etc.