Update plugin for 192.4, rewrite pycharm products page.

This commit is contained in:
JohnHake 2019-11-12 23:56:58 -08:00
parent 81ed6b72f2
commit b551bd91c3
3 changed files with 26 additions and 11 deletions

View File

@ -22,6 +22,7 @@ dependencies {
intellij {
version '2019.2.4'
type 'PY'
updateSinceUntilBuild = false
}
patchPluginXml {

View File

@ -9,8 +9,8 @@
<!-- The version of this plugin -->
<version>0.1.0</version>
<!-- Must match the PyCharm build -->
<idea-version since-build="192.3"/>
<!-- Must match the target PyCharm build -->
<idea-version since-build="192.4"/>
<!-- Requires the python plugin to run -->
<depends>com.intellij.modules.python</depends>

View File

@ -1,19 +1,33 @@
---
title: PyCharm
title: PyCharm Plugin Development
---
## Which API should be used by PyCharm plugin developers?
## Introduction
PyCharm is an IntelliJ Platform-based product.
Plugin projects for PyCharm can be developed using IntelliJ IDEA with the Gradle plugin.
### Platform Open API
## Configuring Plugin Projects Targeting PyCharm
The configuration of PyCharm plugin projects follows the methods described in [Configuring Plugin Projects using a Product-Specific Attribute](dev_alternate_products.md#configuring-plugin-projects-using-a-product-specific-attribute), and [Configuring the plugin.xml File](dev_alternate_products.md#configuring-the-plugin-pluginxml-file).
The table below summarizes the attributes to set in the `build.gradle` file:
The APIs from the standard set of Platform Open API modules can be safely used in plugins. Public symbols defined in these modules have a lifecycle, and will be marked as deprecated for several releases before being removed.
| Gradle Plugin Attribute | Value |
|-----------|-------|
| `intellij.type` | `PY` or `PC` |
| `intellij.version` | Match the targeted `PY` or `PC` version |
| `intellij.plugins` | No specific declaration is needed to use `PY` or `PC` APIs |
| `runIde.ideaDirectory` | Not needed; the Development Instance will automatically match `intellij.type` |
The modules are [defined in the `CommunityRepositoryModules.groovy` file](upsource:///platform/build-scripts/groovy/org/jetbrains/intellij/build/CommunityRepositoryModules.groovy).
The dependency on the PyCharm APIs must be declared in the `plugin.xml` file.
As described in [Modules Specific to Functionality](/basics/getting_started/plugin_compatibility.md#modules-specific-to-functionality) table, the `<depends>` tags must declare `com.intellij.modules.python`
### PyCharm Open API
See the SDK code sample [`pycharm_basics`](https://github.com/JetBrains/intellij-sdk-docs/tree/master/code_samples/product_specific/pycharm_basics/) for an example configuration.
Symbols defined in the **python-psi-api** and **python-openapi** modules are also public API and considered stable.
## Available PyCharm APIs
The APIs from the set of [Modules Available in All Products](/basics/getting_started/plugin_compatibility.md#modules-available-in-all-products) can be used in PyCharm plugins.
APIs for PyCharm Professional are defined in the plugin [Python](https://plugins.jetbrains.com/plugin/631-python).
The APIs for PyCharm Community are defined in the plugin [Python Community Edition](https://plugins.jetbrains.com/plugin/7322-python-community-edition/).
These are considered stable APIs, but care should be taken to test your plugin with any version of PyCharm you wish to support.
### Other API
## Additional Articles and Resources
Classes and methods defined in other modules are used at your own risk, and care should be taken to test your plugin with any version of PyCharm you wish to support.
## Open Source Plugins for PyCharm