PHPStorm plugin that developed by me cannot be installed
Hi,
I am developing a PHPStorm plugin which add a menu item in Tools menu. It works well on IDEA CE, but shows "incompatible with the current phpstorm version" message on PHPStorm.
Details as flowing:
Section 1. Version of IDE I installed:
IDEA CE:
PHPStorm:
Section 2. When plugin runs on IDEA CE, Configurations are:
build.grade :
intellij {
version '2019.2.4'
}
This works well.
Section 3. When plugin runs on PHPStorm:
build.grade :
intellij {
version '2019.2.4'
plugins ['com.jetbrains.php']
}
runIde {
ideDirectory '/Applications/PhpStorm.app/Contents'
}
plugin.xml:
<idea-plugin>
//...
<depends>com.jetbrains.php</depends>
<depends>com.intellij.modules.platform</depends>
//...
</idea-plugin>
PHPStorm plugins page shows error:
incompatible with the current phpstorm version
Section 4. If Change intellij.version:
intellij {
version '193.5233.102'
plugins ['com.jetbrains.php']
}
runIde {
ideDirectory '/Applications/PhpStorm.app/Contents'
}
Configuration build takes a long time:
And error in the end:
A problem occurred configuring root project 'gci'.
> Could not resolve all files for configuration ':detachedConfiguration1'.
> Could not download ideaIU.zip (com.jetbrains.intellij.idea:ideaIU:193.5233.102)
> Could not get resource 'https://cache-redirector.jetbrains.com/www.jetbrains.com/intellij-repository/releases/com/jetbrains/intellij/idea/ideaIU/193.5233.102/ideaIU-193.5233.102.zip'.
> Could not GET 'https://www.jetbrains.com/intellij-repository/releases/com/jetbrains/intellij/idea/ideaIU/193.5233.102/ideaIU-193.5233.102.zip'.
> Read timed out
I am in china.This seems like a GFW network problem.
My Questions are:
1. Can i download ideaIU-193.5233.102.zip manually and put is somewhere ? If can, Where should it be?
2. I have installed ideaIU:193.5233.102 as the first image shows,Why Gradle download it again?
3. In Section 3 above, intellij.version 2019.2.4 is small than PHPStorm verion 2019.3, Should it be bigger or must be equal?
Thanks
Please sign in to leave a comment.
I'm a bit confused, does your plugin actually require API from PhpStorm/PHP Plugin or not?
The plugin don't require PHPStorm API。
What the plugin done is : add a menu item at menu bar , open a swing dialog when use click it。
The dialog shows some textfields , The plugin generates a config file and save to project root dir when ok button in dialog clicked.
You shouldn't change "intellij" block to run your plugin on different IDE than IJ Community, only change "runIde".
See http://www.jetbrains.org/intellij/sdk/docs/products/dev_alternate_products.html and http://www.jetbrains.org/intellij/sdk/docs/basics/getting_started/plugin_compatibility.html
Thank you for your reply.
Configuration now is :
plugin.xml, uncomment the depends:
build.gradle:
PhpStorm starts OK and version is 2019.3, but:
If version changed:
ideaIC-2019.3.zip downloads error:
A problem occurred configuring root project 'gci'.
> Could not resolve all files for configuration ':detachedConfiguration1'.
> Could not download ideaIC.zip (com.jetbrains.intellij.idea:ideaIC:2019.3)
> Could not get resource 'https://cache-redirector.jetbrains.com/www.jetbrains.com/intellij-repository/releases/com/jetbrains/intellij/idea/ideaIC/2019.3/ideaIC-2019.3.zip'.
> Could not GET 'https://cache-redirector.jetbrains.com/www.jetbrains.com/intellij-repository/releases/com/jetbrains/intellij/idea/ideaIC/2019.3/ideaIC-2019.3.zip'.
> cache-redirector.jetbrains.com: nodename nor servname provided, or not known
Please check the documentation links carefully.
<depends>com.intellij.modules.platform</depends>
is required to make plugin work in other IDE than IntelliJ IDEA.
Thank you ! It works now!