I'm developing an IDEA plugin and I use Maven to manage my library dependencies and to build the final source and binary artifacts. But during development I would like to use IDEA's Make and Run to launch the plugin and test it. The problem is that in my pom.xml I have dependencies to some libraries (such as IDEA's openapi and a bunch of testing frameworks) which must not be copied to the \plugins-sandbox\plugins\*\lib folder when I run the plugin - including the openapi jar causes my plugin to not load.
Dependencies in my pom.xml are (the IDEA jars are in my local Maven repository, so that I can build the plugin with Maven):
When I run the plugin module within IDEA, the following files are copied to the plugins-sandbox:
The library which causes problems is openapi-188.8.131.5264.jar. When it is present, my plugin will fail with the following exception:
java.lang.IllegalStateException: class with name "net.orfjackal.extformatter.plugin.ReformatAction" should be instance of com.intellij.openapi.actionSystem.AnAction
I've tried unchecking the Export checkboxes for the libraries in Module Settings, but that doesn't help. IDEA's plugin deployer should not include to the plugin package those libraries which are marked as a compile/provided/test/system scope dependencies in pom.xml. Only runtime scope dependencies should be included.