Start Run configuration without showing tool window?

In my plugin, the user can create run configurations which are used to start REPL processes. These processes appear in a non-standard toolwindow which is usually docked on the side, rather than the usual run toolwindow which is normally at the bottom. It was very difficult to come up with a way to run these configurations without showing the default toolwindow - I basically had to implement my own Runner extending DefaultJavaProgramRunner, and then completely replace the execute() method with code that was cut and pasted from GenericProgramRunner.execute(), DefaultJavaProgramRunner.doExecute(), and ExecutionManagerImpl.startRunProfile(). This is very brittle and hard to maintain - I did this around the IntelliJ v14 timeframe and the code underlying the execution framework has changed a lot since then.

Is there a better way to do this? I capture all the process output myself and print it to the REPL console, so I don't want to show the standard Run toolwindow at all.

Another use case is when the user runs a REPL which connects to a remote process. I still want them to use a run config to hold the configuration details and to make it consistent with the local REPL options, but obviously there's no process started there at all. Again, I'd like to not show the default console in this case because it makes no sense.

Please sign in to leave a comment.