home    login

#19

IDE script for JetBrains IDEs that enables you to start multiple configurations in debug mode at once.

Go to Tools->IDE Scripting Console, select Groovy as language of choice and paste the code provided. You have to select all lines and press CTRL+ENTER to run the script.

Some people won't have IDE scripting option visible in the menus so you'll have to create manual keystroke binding to open it. Just make sure that you replace configuration names with your own :-)

multiRun = [
  "IRB console: [local] document_storage_service",
  "IRB console: [local] metadata_service",
  "IRB console: [local] table_storage_service",
];

allSettings = com.intellij.execution.RunManager.getInstance(com.intellij.openapi.project.ProjectManager.getInstance().getOpenProjects()[0]).getAllSettings();
executor = com.intellij.execution.ExecutorRegistry.getInstance().getExecutorById(com.intellij.openapi.wm.ToolWindowId.DEBUG);

toBeRun = allSettings.findAll { setting ->
  multiRun.any { setting.toString() == it }
}.each {
    com.intellij.execution.runners.ExecutionUtil.runConfiguration(it, executor);
}