krasa / GrepConsole

IntelliJ plugin - https://plugins.jetbrains.com/plugin/7125
Apache License 2.0
437 stars 57 forks source link

How to make Grep Console highlight run configurations? #112

Closed gxcross closed 6 years ago

gxcross commented 6 years ago

In IntelliJ, if I run a configuration (grunt) the output to console is not colorized by Grep Console. However, if I right-click a word in the console output and "Grep" that, then everything is colorized properly. How do I make Grep Console run by default for my Run configurations?

Thanks!

krasa commented 6 years ago

Normally https://github.com/JetBrains/intellij-community/blob/master/platform/lang-impl/src/com/intellij/execution/impl/ConsoleViewImpl.java#L276 should be called (that provides a coloring filter), if it is not, then JetBrains or whoever makes Grunt plugin could fix it. There is nothing I can do.

But maybe it would be possible to call this manually - not automatically, as a workaround https://github.com/JetBrains/intellij-community/blob/master/platform/lang-impl/src/com/intellij/execution/impl/ConsoleViewImpl.java#L850 You would have to right click in the console and select an action which would add a coloring filter.

gxcross commented 6 years ago

darn, okay thanks.. was hoping it was just a configuration error on my part. Odd thing is that in the console, I see the "grep console" button.. so it's there, but it's not applying it to the output.

krasa commented 6 years ago

"grep console" button triggers my code, and I create a whole new console correctly, and the button is created in a different integration point, that's why it's there :)

Looking at it, maybe it will be possible to do the workaround automatically. I will try it tomorrow.

gxcross commented 6 years ago

awesome, thank u!

krasa commented 6 years ago

Try to install this https://github.com/krasa/GrepConsole/releases/download/8.3.162.000.0/GrepConsole.zip (without extracting)

gxcross commented 6 years ago

omg!! you are awesome, it works! thank you so much!

image

gxcross commented 6 years ago

wow, even saw you updated the plugin already too! thx again for your quick reply and responsiveness!!

krasa commented 6 years ago

No problem! And thanks for reporting it.