Finding Maven coordinates for IntelliJ platform artifacts

已回答

I am refactoring common code used by multiple plugins into a library. The library needs to use IntelliJ platform classes, but I cannot figure out the correct Maven coordinates to put into my Gradle build file.

For example, my library needs the com.intellij.credentialStore.Credentials class. I'm loading com.jetbrains.intellij.platform:credential-store:<version>, as found at the IntelliJ repository, into my project, but the Credentials class does not exist in the package. Is there a way to find the Maven artifact that contains a given class definition?

Gradle build file:

plugins {
id("org.jetbrains.kotlin.jvm") version "1.7.10"
id("java-library")
}

repositories {
mavenCentral()
maven("https://www.jetbrains.com/intellij-repository/releases")
}

dependencies {
val platformVersion = "221.6008.15"
implementation(platform("org.jetbrains.kotlin:kotlin-bom"))
implementation("com.jetbrains.intellij.platform:credential-store:${platformVersion}")
implementation("com.jetbrains.intellij.platform:credential-store-ui:${platformVersion}")
testImplementation(kotlin("test"))
}

 

0

Pointing to the direct artifacts in the IntelliJ Maven repository is not recommended. Could you please try using the Gradle IntelliJ Plugin instead to resolve platform dependencies?

0

Jakub Chrzanowski

Thank you, using the IntelliJ plugin worked to find my dependencies. Do I have I do any special configuration to build a standalone library instead of an IntelliJ plugin? Or, is a plugin just a library with extra metadata (plugin.xml)?

0

请先登录再写评论。