Merge pull request #112 from JohnHake/ijsdk-47

ijsdk-47 Relaced settings, caches, logs page with pointer to kb record.
This commit is contained in:
Dmitry Jemerov 2018-09-14 10:06:46 +02:00 committed by GitHub
commit bfc37dec8b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 90 additions and 73 deletions

View File

@ -34,7 +34,7 @@
* [Plugin Configuration File](basics/plugin_structure/plugin_configuration_file.md)
* [Plugin Dependencies](basics/plugin_structure/plugin_dependencies.md)
* [Kotlin for Plugin Developers](tutorials/kotlin.md)
* [Troubleshooting](basics/settings_caches_logs.md)
* [IDE Development Instances](basics/ide_development_instance.md)
* [Plugin Development FAQ](faq.md)
## Part II - Base Platform
@ -240,6 +240,7 @@
* [Introduction](resources.md)
* [IntelliJ Community Edition on GitHub](https://github.com/JetBrains/intellij-community)
* [IDE Settings, Caches, Logs, and Plugins](https://intellij-support.jetbrains.com/hc/en-us/articles/206544519-Directories-used-by-the-IDE-to-store-settings-caches-plugins-and-logs)
* [IntelliJ Plugins](https://github.com/JetBrains/intellij-plugins)
* [IntelliJ Scala Plugin](https://github.com/JetBrains/intellij-scala)
* [Gradle IntelliJ Plugin](https://github.com/JetBrains/gradle-intellij-plugin)

View File

@ -9,5 +9,5 @@ It will familiarize you with the working environment, project structure, and fre
* [Getting Started](basics/getting_started.md)
* [Plugin Structure](basics/plugin_structure.md)
* [Kotlin for Plugin Developers](/tutorials/kotlin.md)
* [IDE Settings, Caches, Logs, and Plugins](basics/settings_caches_logs.md)
* [IDE Development Instances](basics/ide_development_instance.md)
* [Plugin development FAQ](faq.md)

View File

@ -5,7 +5,7 @@ title: Creating a Plugin Project
This section explains how you can create a new plugin project from scratch using the New Project wizard. Optionally, you can import an existing project or import a project from external models. You can also add a new plugin module to an existing *IntelliJ Platform* project.
For more information, refer to the [IntelliJ IDEA Web Help](https://www.jetbrains.com/idea/help/new-project-wizard.html).
## To create a plugin project:
### To Create an IntelliJ Platform Plugin Project:
* On the main menu, choose **File \| New \| Project**. The *New Project*
wizard starts.
@ -17,3 +17,16 @@ For more information, refer to the [IntelliJ IDEA Web Help](https://www.jetbrain
* Set desired project name
* Click **Finish** to generate project structure files
* Go to **File \| Project Structure** to customize project settings if required
### To Create an IntelliJ Platform Plugin Module
* Select **File \| New \| Module** and choose the *IntelliJ Platform Plugin* module type
![IntelliJ Platform Plugin Module](img/intellij_platform_plugin_module.png)
<br/>
<br/>
* Enter your desired plugin name.
* Go to **File \| Project Structure** and select the newly created *IntelliJ Platform SDK* as the default SDK for the plugin module:
![Set Plugin Module SDK](img/set_plugin_module_sdk.png)

View File

@ -6,8 +6,8 @@ Before your custom plugin can be used, it must be deployed: built, installed, an
To deploy a plugin:
* Make your project by invoking **Build \| Make Project**.
* Prepare your plugin for deployment. In the main menu, select **Build \| Prepare Plugin Module '\<module name\>' for Deployment**.
* Make your project by invoking **Build \| Build Project** or **Build \| Build Module \<module name\>**.
* Prepare your plugin for deployment. In the main menu, select **Build \| Prepare Plugin Module \<module name\> for Deployment**.
![Prepare Plugin for Deployment](deploying_plugin/img/prepare_plugin_for_deployment.png)
@ -15,12 +15,10 @@ To deploy a plugin:
![Jar Saved Notification](deploying_plugin/img/jar_saved_notification.png)
* Copy the newly created archive file to the `.IntelliJIDEAx0\config\plugins` folder, and then restart your IDE so the changes may take effect. To know how to locate your *plugins* directory, refer to [IDE Settings, Caches, Logs, and Plugins](/basics/settings_caches_logs.md).
* [Install](https://www.jetbrains.com/help/idea/managing-plugins.html#installing-plugins-from-disk)
the newly created archive/jar file from disk. The `editor_basics` code sample builds the plugin archive/jar into the `editor_basics` project folder:
![Jar File Location](deploying_plugin/img/jar_location.png)
* In the main menu, select **File \| Settings** to open the Settings dialog box.
* In the Settings dialog box, under **IDE Settings**, click **Plugins**.
* In the Plugins area, open the **Installed** tab, and then select the check-box next to your plugin name.
* When finished, click OK to close the Settings dialog box.
* Restart the IDE so that your changes take effect.
* Restart your IDE so the changes will take effect.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

After

Width:  |  Height:  |  Size: 60 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 88 KiB

After

Width:  |  Height:  |  Size: 100 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

View File

@ -40,13 +40,12 @@ To set up your plugin development environment:
![Specify Source Paths](img/community_sources_directory.png)
<br/>
<br/>
* Select **File \| New \| Module** and choose the *IntelliJ Platform Plugin* module type
![IntelliJ Platform Plugin Module](img/intellij_platform_plugin_module.png)
<br/>
<br/>
* Enter your desired plugin name.
* Go to **File \| Project Structure** and select the newly created *IntelliJ Platform SDK* as the default SDK for the plugin module:
![Set Plugin Module SDK](img/set_plugin_module_sdk.png)
* Specify the **Sandbox Home** directory.
The *Sandbox Home* directory stores the settings of the IDE development instance launched from a Plugin Project's **Run** configration.
Shown below is the default *Sandbox Home* directory for a user on Mac OS X. Any directory can be chosen as the *Sandbox Home* location.
Use the ellipsis button (shown below) to define a custom location.
See the [IDE Development Instances](/basics/ide_development_instance.md) page for more information about default *Sandbox Home* directory
locations and contents.
![Specify Sandbox Path](img/plugins-sandbox.png)

View File

@ -0,0 +1,39 @@
---
title: IDE Development Instances - Settings, Caches, Logs, and Plugins
---
A JetBrains feature for developing plugins is to run or debug a plugin project from within a JetBrains IDE, e.g. IntelliJ IDEA.
[Selecting the **Run** menu](https://www.jetbrains.com/help/idea/running-and-debugging-plugins.html) will launch
a _Development Instance_ of the IDE with your plugin enabled.
The **Sandbox Home** directory contains the
[settings, caches, logs, and plugins](#development-instance-settings-caches-logs-and-plugins)
for a Development Instance of the IDE. This information is stored in a different location than for the
[installed IDE itself](https://intellij-support.jetbrains.com/hc/en-us/articles/206544519-Directories-used-by-the-IDE-to-store-settings-caches-plugins-and-logs).
### Sandbox Home Location for Gradle-Based Plugin Projects
For Gradle-based plugins, the default **Sandbox Home** location is defined by the IntelliJ Platform `gradle-intellij-plugin`.
See [Configuring a Gradle Plugin Project](/tutorials/build_system/prerequisites.md)
for more information about specifying a **Sandbox Home** location. The default **Sandbox Home** location
for Gradle-based plugin projects is:
* **Windows** `<Project Dir>\build\idea-sandbox`
* **Linux or macOS** `<Project Dir>/build/idea-sandbox`
### Sandbox Home Location for DevKit-Based Plugin Projects
For DevKit-based plugins, the default **Sandbox Home** location is defined in the IntelliJ Platform Plugin SDK.
See specifying the [Sandbox Home for DevKit Projects](/basics/getting_started/setting_up_environment.md) for more information.
The default **Sandbox Home** directory location for DevKit-based plugin projects is:
* **Windows:** `<User home>\.<product_system_name><product_version>\system\plugins-sandbox\`
* **Linux:** `~/.<product_system_name><product_version>/system/plugins-sandbox/`
* **macOS** `~/Library/Caches/<product_system_name><product_version>/plugins-sandbox/`
### Development Instance Settings, Caches, Logs, and Plugins
Within the **Sandbox Home** directory are subdirectories pertaining to the Development Instance:
* `config` contains settings for the IDE instance.
* `plugins` contains folders for each plugin being run in the IDE instance.
* `system/caches` or `system\caches` holds the IDE instance data.
* `system/log` or `system\log` contains the `idea.log` file for the IDE instance.
Each of these **Sandbox Home** subdirectories can be manually cleared to reset the IDE Development Instance.
At the next launch of a Development Instance the subdirectories will be repopulated with the appropriate information.

View File

@ -1,45 +0,0 @@
---
title: Settings, Caches, Logs, and Plugins
---
Every IntelliJ-based IDE stores its local settings, caches, log and installed plugins on a hard drive. Location of the IDE files depends on the operating system, product and version. IDE settings directory name is made up of the product code name and product version. We will use `<product_system_name><product_version>` as an alias for the product internal settings home directory name.
## Directory locations
* **Windows:** You can find internal configuration data in `<User home>\.<product_system_name><product_version>`
* **Linux:** You can find internal configuration data in `~/.<product_system_name><product_version>`
In the folder you can find two subdirectories:
* `config` that contains user-specific settings.
* `system` that stores `IntelliJ Platform` data caches.
* **Mac OS X:** You can find internal configuration data in:
* `/Applications/<product_system_name><product_version>/Contents/plugins` contains the catalog with plugins.
* `~/Library/Preferences/<product_system_name><product_version>` contains the rest of the configuration settings.
* `~/Library/Caches/<product_system_name><product_version>` contains data caches, logs, local history, etc.
These files can be quite significant in size.
* `~/Library/Logs/<product_system_name><product_version>` contains logs.
## Product System Names
| Product name | Directory name prefix |
|---------------------------------|----------------------:|
| IntelliJ IDEA Ultimate Edition | `IntelliJIdea` |
| IntelliJ IDEA Community Edition | `IdeaIC` |
| RubyMine | `RubyMine` |
| WebStorm (7.0+) | `WebStorm` |
| PhpStorm and WebStorm (pre-7.0) | `WebIde` |
| PyCharm | `PyCharm` |
| AppCode | `appCode` |
| CLion | `clion` |
| DataGrip | `DataGrip` |
## Example
To go to the *IntelliJ IDEA 14* plugin directory on Mac execute the following command:
```bash
cd /Applications/IntelliJ\ IDEA\ 14.app/Contents/plugins
```

View File

@ -5,6 +5,7 @@ title: Resources
The following links represent useful resources for working with the _IntelliJ Platform_ and creating plugins.
* [IntelliJ Community Edition on GitHub](https://github.com/JetBrains/intellij-community)
* [IDE Settings, Caches, Logs, and Plugins](https://intellij-support.jetbrains.com/hc/en-us/articles/206544519-Directories-used-by-the-IDE-to-store-settings-caches-plugins-and-logs)
* [IntelliJ Plugins](https://github.com/JetBrains/intellij-plugins)
* [IntelliJ Scala Plugin](https://github.com/JetBrains/intellij-scala)
* [Gradle Plugin for Grammar-Kit](https://github.com/hurricup/gradle-grammar-kit-plugin)

View File

@ -1,20 +1,20 @@
---
title: Getting Started
title: Getting Started with Gradle
---
Adding Gradle build support to an IntelliJ Platform Plugin requires a recent distribution to the Gradle build system and IntelliJ IDEA (Community or Ultimate).
### 1.0. Download and install IntelliJ IDEA
### 1.0 Download and Install IntelliJ IDEA
Download and install either IntelliJ IDEA Ultimate or the IntelliJ IDEA Community Edition.
### 1.1. Ensure the Gradle plugin and 'Plugin DevKit' plugin are enabled
### 1.1 Ensure the Gradle Plugin and 'Plugin DevKit' Plugin are Enabled
You can verify that the plugins are enabled by visiting **Settings \| Plugins**.
<img src="img/step0_gradle_enabled.png" alt="Ensure the Gradle plugin is enabled" width="858px"/>
### 1.2. Create plugin project from scratch
### 1.2 Create a Plugin Project from Scratch
IntelliJ IDEA supports automatically creating new plugin projects using Gradle, with all the necessary build.gradle
setup performed automatically. This can also be used to convert an existing plugin to Gradle, if Gradle is not able to
@ -35,8 +35,19 @@ Finally, specify a JVM Gradle will use, it can be the Project JDK. You also conf
<img src="img/step3_gradle_config.png" alt="Verify the JVM is the correct version" width="800px"/>
### 1.3. Add Gradle support to an existing plugin
### 1.3 Configuring a Gradle Plugin Project
Support for Gradle-based plugin projects is provided by the IntelliJ Platform `gradle-intellij-plugin`.
See the [Gradle plugin README](https://github.com/JetBrains/gradle-intellij-plugin/blob/master/README.md#gradle) for more information.
For example, to configure the **Sandbox Home** directory's location include the following in the project's `build.gradle` file:
```groovy
intellij {
sandboxDirectory = "$project.buildDir/myCustom-sandbox"
}
```
See the [IDE Development Instances](/basics/ide_development_instance.md)
page for more information about default Sandbox Home directory locations and contents.
### 1.4 Add Gradle Support to an Existing Plugin
To add Gradle support to an existing plugin project, create a `build.gradle` file under the root directory, with at least the following contents:
@ -73,7 +84,7 @@ gradle cleanIdea idea
This will clean any existing IntelliJ IDEA configuration files and generate a new Gradle build configuration recognized by IntelliJ IDEA. Once your project refreshes, you should be able to view the Gradle tool window displayed under **View \| Tool Windows \| Gradle**. This indicates that IntelliJ IDEA recognizes the Gradle facet.
### 1.4. Running a simple plugin
### 1.5 Running a Simple Plugin
Now add a new `HelloAction` class and `plugin.xml` in the `META-INF` folder: