How to send commands to the Terminal View
What I want to do is, to trigger an action of some sort / or press some button, that (optionally generates the selected model and) executes an existing (generated) artifact in the Terminal View. Since I generate a configuration file for a binary that also requires user interaction, I need to run it in the terminal view and not just execute it in the background.
Basically, I want to programmatically execute "export PATH=$PATH:bla/b; ~/path/of/some/sort/BINARY -c ARTIFACT.txt" in the Terminal View. Any idea how I can achieve that?
I hope that was understandable :D
Thanks in advance!
Please sign in to leave a comment.
Hi! You can extend the class LocalTerminalDirectRunner and implement the method createProcess
Then if you execute run method a terminal panel should be created with the corresponding process.
Hi, thanks for your suggestion! However, It seems that LocalTerminalDirectRunner does not exist for me... Is there a particular package or stubs that I need to import. Using CTRL+R I am not able to find that class though.
You can find it in the module terminal of the intellij-community source base.