How to display step by step output of my custom plugin execution?

Answered

I am writing a plugin that will execute a list of steps, by invoking a command line tool in response to an action clicked by the user. I am able to us the

com.intellij.execution.configurations.GeneralCommandLine

class to run the command. 

and 

com.intellij.execution.process.OSProcessHandler

to display the output. However, this seems to execute the configured command and display the output of all steps together in the intelliJ terminal. I would like to not simply display the direct output of CLI execution of all steps, but would rather like to display the output of each step separately. Similar to the output of running Junit tests, where each test case is clickable in the output and shows its own terminal logs. 

Please sign in to leave a comment.