diff --git a/build.gradle b/build.gradle index e61e7e665..dcb8966e2 100644 --- a/build.gradle +++ b/build.gradle @@ -1,5 +1,5 @@ -import org.jetbrains.intellij.platform.gradle.TestFrameworkType import org.jetbrains.intellij.platform.gradle.IntelliJPlatformType +import org.jetbrains.intellij.platform.gradle.TestFrameworkType plugins { id "org.jetbrains.intellij.platform" version "2.0.0" @@ -154,24 +154,17 @@ test { } intellijPlatformTesting { - def platforms = [ - "IntellijIdeaCommunity", - "IntellijIdeaUltimate", - "RubyMine", - "RustRover", - "PyCharmCommunity", - "PyCharmProfessional", - "WebStorm" - ] + // Get the list of platforms from gradle.properties + def platformsList = providers.gradleProperty("platformsList").get().split(",") // Use providers.gradleProperty to get the 'runIdePlugins' property def runIdePluginsProperty = providers.gradleProperty("runIdePlugins").getOrElse("") def runIdePluginsList = runIdePluginsProperty.split(",") - platforms.each { platform -> + platformsList.each { platform -> runIde.create("run${platform}") { type = IntelliJPlatformType."${platform}" - version = providers.gradleProperty("platformVersion") + version = providers.gradleProperty("platformVersion${platform}").get() prepareSandboxTask { sandboxDirectory = project.layout.buildDirectory.dir("${platform.toLowerCase()}-sandbox") } diff --git a/gradle.properties b/gradle.properties index c042fcfcc..5868f3583 100644 --- a/gradle.properties +++ b/gradle.properties @@ -12,6 +12,17 @@ pluginUntilBuild=242.* # Set this to open runIdeWorkingDirectory= +# Define versions for running the IDEs, as each IDE can release at different release versions. +platformVersionIntellijIdeaCommunity=2024.2.0.1 +platformVersionIntellijIdeaUltimate=2024.2.0.1 +platformVersionRubyMine=2024.2 +platformVersionPyCharmCommunity=2024.2 +platformVersionPyCharmProfessional=2024.2 +platformVersionWebStorm=2024.2 + +# Comma-separated list of platforms to include +platformsList=IntellijIdeaCommunity,IntellijIdeaUltimate,RubyMine,PyCharmCommunity,PyCharmProfessional,WebStorm + # The versions we target, 21 is needed for IntelliJ Plugins javaVersion=21 javaTargetVersion=21