Unable to access JAR included in IntelliJ plugin from preloading activity

已回答

I've included a language server JAR in the lib folder of my IntelliJ plugin for my custom language plugin. I've also added it under dependencies in my build.gradle file like so:

compile files('lib/MyLangServer-1.1.jar')

I'm trying to access/run this jar from a preloading activity and while I can use idea.plugins.path to access the correct path to the installed jar when using runIde to test a sandbox instance of the plugin, when I build the plugin and install it from disk as a zip, the path is now returning null.

Is this the correct way to reference the jar, or is there another way that I'm missing, or could there be some other issue? Thanks in advance.

0

Hi,

I don't fully get the use case, but this JAR doesn't sound like a plugin dependency but a resource, so I would go with adding it to the resources directory and use it like other resources.

0

请先登录再写评论。