Dependency on 3rd party plugin (SonarLint)
Answered
Hi,
I would like to for users of our plugin to install also https://plugins.jetbrains.com/plugin/7973-sonarlint and it's API. I know there is depends tag but I suppose it's only for Jetbrains plugin?
Thank you.
Please sign in to leave a comment.
No, 'depends' tag should work for all plugins. Just specify 'id' of the required plugin in it (org.sonarlint.idea for SonarLint plugin).
Thank for quick reply.
I am not sure but I saw message during installation of some plugin that is dependent on another plugin with confirm dialog that will be also installed. But when I use mentioned plugin id I am getting unresolved message on id text (it's red) and during installation there is only error message that another unknown plugin (but not mentioned which) and plugin won't load.
I am facing the same issue, my plugin depends on "org.eclipse.xtext.idea" plugin which is hosted at https://download.eclipse.org/modeling/tmf/xtext/idea/2.10.0/updatePlugins.xml
I am using <depends>org.eclipse.xtext.idea</depends> in my plugin's definition in plugins.xml file in my repository:
<?xml version="1.0" encoding="UTF-8"?>
<plugins>
<!-- <plugin
id="org.eclipse.xtext.idea"
url="http://download.eclipse.org/modeling/tmf/xtext/idea/2.10.0/org.eclipse.xtext.idea-2.10.0.zip"
version="2.10.0"
/> -->
<plugin
id="my.plugin.id"
url="my.plugin.url"
version="1.0.0">
<name>My Plugin Name</name>
<description>
My plugin description.
</description>
<depends>org.eclipse.xtext.idea</depends>
</plugin>
</plugins>
Installation of my plugin fails (saying it couldn't load "org.eclipse.xtext.idea") until I uncomment the commented definition of the dependency "org.eclipse.xtext.idea" above. It'd be convenient if <depends> tag itself could support the url parameter in it like below:
<depends url="http://download.eclipse.org/modeling/tmf/xtext/idea/2.10.0/org.eclipse.xtext.idea-2.10.0.zip">org.eclipse.xtext.idea</depends>
This way we need not define a 3rd party (dependency) plugin inside our repository's plugins.xml. What do you think?
Also, how does the manifest file work for supporting depends tag? I see in this file that there are two kinds of depends:
Is this the standard format for supporting optional and non-optional dependencies?