After months of refactoring, development, and disc...
# community-news
j
After months of refactoring, development, and discussions about how the Gradle IntelliJ Plugin 1.x should work and why its name is confusing, we have finally reached the point where we can publicly announce the Early Access Preview release! I’m delighted to present the very first IntelliJ Platform Gradle Plugin 2.0 EAP release of the Gradle plugin for creating plugins for IntelliJ-based IDEs (that includes IntelliJ IDEA, PhpStorm, PyCharm, Android Studio, and more). As you have noticed, the 2.0 release got a very new name, but there is way more than just that: • New ID: org.jetbrains.intellij.platform • More powerful intellijPlatform {} extension • Reworked dependencies and repositories management • Better documentation • Simpler configuration structure • Better support for multi-module projects The IntelliJ Platform Gradle Plugin 2.0 EAP release is now available via the snapshots channel. Visit the IntelliJ SDK Docs pages to see how to start using the 2.0 version. You’ll also find the migration guide, which will be updated daily with more and more details to make this process smooth. Call to action: If you develop a plugin for IntelliJ-based IDEs, please join us at this stage and share any questions, design suggestions, or problems you will face, so the 2.0 GA will be as solid as rock! What’s the best approach for that? Take your plugin project and open the
build.gradle.kts
file, and follow the Migration Guide. Docs: https://plugins.jetbrains.com/docs/intellij/tools-intellij-platform-gradle-plugin.html Cheers! Jakub, Developer Advocate for IntelliJ Platform SDK @ JetBrains
👍 1
👀 1
🚀 5
🙌 3
🎉 4
f
Thank you very much for your work on this! I’ve been waiting for this announcement 😄 Unfortunately I run into this error even though I’ve added the mentioned repository in the settings.gradle.kts (as you can also see from the output):
Copy code
Plugin [id: 'org.jetbrains.intellij.platform', version: '2.0.0-SNAPSHOT'] was not found in any of the following sources:

- Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
- Plugin Repositories (could not resolve plugin artifact 'org.jetbrains.intellij.platform:org.jetbrains.intellij.platform.gradle.plugin:2.0.0-SNAPSHOT')
  Searched in the following repositories:
    maven(<https://oss.sonatype.org/content/repositories/snapshots/>)
    maven2(https://<company-internal maven repo>)
    Gradle Central Plugin Repository
Any idea what I’m missing?
j
@Florian Dreier This is strange. The following entry in the
settings.gradle.kts
should be enough
Copy code
pluginManagement {
    repositories {
        maven("<https://oss.sonatype.org/content/repositories/snapshots/>")
        gradlePluginPortal()
    }
}
to use EAP release in
build.gradle.kts
Copy code
plugins {
  id("org.jetbrains.intellij.platform") version "2.0.0-SNAPSHOT"
}
f
That’s exactly what I did. Even tried
./gradlew help --refresh-dependencies
now, but same result. But I also don’t seem to be able to access the SNAPSHOT manually via https://oss.sonatype.org/content/repositories/snapshots/org/jetbrains/intellij/platfo[…]jetbrains.intellij.platform.gradle.plugin-2.0.0-SNAPSHOT.pom
f
Ah, true 🤔
d
Is there a sample working example project I can look at? (Sorry if it's linked in the docs and I missed it) In my own project, I'm getting > FAILURE: Build failed with an exception. > > * Where: > Initialization script '/tmp/ijresolvers1.gradle' line: 136 > > Failed to notify task execution graph listener. > > /.../plugin/build/tmp/patchPluginXml/plugin.xml When I try to open
patchPluginXml/plugin.xml
, it's not found. I'll attach
/tmp/ijresolvers1.gradle
to this comment, but the line complaining is
for (arg in task.getAllJvmArgs() + task.getJvmArgs())
I'd like to compare what I'm doing with a real project. (I moved some values out of plugin.xml and patchPlugin and put them into the new
intellijPlatform
block for example). I'll keep poking around and will paste any significant updates if things change.
ijresolvers1.gradle
Also, code doesn't seem to be resolving correctly after migrating. I'm getting
Cannot access 'com.intellij.psi.PsiModifiableCodeBlock' which is a supertype of 'org.jetbrains.kotlin.psi.KtProperty'. Check your module classpath for missing or conflicting dependencies
for example. I don't mean to turn this thread into a bug report though. I think what I really want here is a sample project to clone and compare with. If the team wants more details about my own project (which is running into these issues), please have someone send me a DM. Thanks!