Changesets · Branches · Tags · Compare
| Changeset | 2a19f9e1d9eaf8ca73e4a5a25432aedbafadfefec285dc378cc1e2d08349e928 |
|---|---|
| Author | Jakub Błach <jakubblach@gmail.com> · 2025-07-21 23:12 +02:00 |
| Committer | GitHub <noreply@github.com> · 2025-07-21 14:12 -07:00 |
| Parents | 014c67783591 |
1 file changed
modified extensions/intellij/build.gradle.kts +14 −39
| @@ -9,6 +9,8 @@ | ||
| 9 | 9 | } |
| 10 | 10 | |
| 11 | 11 | val remoteRobotVersion = "0.11.23" |
| 12 | +val isEap get() = environment("RELEASE_CHANNEL").orNull == "eap" | |
| 13 | +val pluginVersion = properties("pluginVersion").get() | |
| 12 | 14 | |
| 13 | 15 | plugins { |
| 14 | 16 | id("java") |
| @@ -22,17 +24,13 @@ | ||
| 22 | 24 | } |
| 23 | 25 | |
| 24 | 26 | group = properties("pluginGroup").get() |
| 27 | +version = if (isEap) "$pluginVersion-eap" else pluginVersion | |
| 25 | 28 | |
| 26 | -version = properties("pluginVersion").get() | |
| 27 | - | |
| 28 | -// Configure project's dependencies | |
| 29 | 29 | repositories { |
| 30 | 30 | mavenCentral() |
| 31 | 31 | maven { url = uri("https://packages.jetbrains.team/maven/p/ij/intellij-dependencies") } |
| 32 | 32 | } |
| 33 | 33 | |
| 34 | -// Dependencies are managed with Gradle version catalog - read more: | |
| 35 | -// https://docs.gradle.org/current/userguide/platforms.html#sub:version-catalog | |
| 36 | 34 | dependencies { |
| 37 | 35 | implementation("com.squareup.okhttp3:okhttp:4.12.0") { |
| 38 | 36 | exclude(group = "org.jetbrains.kotlin", module = "kotlin-stdlib") |
| @@ -48,22 +46,6 @@ | ||
| 48 | 46 | testImplementation("com.squareup.okhttp3:logging-interceptor:4.12.0") |
| 49 | 47 | testImplementation("com.automation-remarks:video-recorder-junit5:2.0") |
| 50 | 48 | testImplementation("org.jetbrains.kotlinx:kotlinx-coroutines-test:1.7.3") |
| 51 | - | |
| 52 | - | |
| 53 | - // Exclude vulnerable Log4j from all dependencies | |
| 54 | - configurations.all { | |
| 55 | - resolutionStrategy { | |
| 56 | - eachDependency { | |
| 57 | - if (requested.group == "log4j" && requested.name == "log4j") { | |
| 58 | - useTarget("org.slf4j:log4j-over-slf4j:1.7.36") | |
| 59 | - } | |
| 60 | - } | |
| 61 | - } | |
| 62 | - } | |
| 63 | - | |
| 64 | - // Add Log4j 2.x explicitly | |
| 65 | - implementation("org.apache.logging.log4j:log4j-core:2.20.0") | |
| 66 | - implementation("org.apache.logging.log4j:log4j-api:2.20.0") | |
| 67 | 49 | testImplementation(kotlin("test")) |
| 68 | 50 | } |
| 69 | 51 | |
| @@ -105,7 +87,7 @@ | ||
| 105 | 87 | |
| 106 | 88 | tasks { |
| 107 | 89 | downloadRobotServerPlugin { |
| 108 | - version.set(remoteRobotVersion) | |
| 90 | + version = remoteRobotVersion | |
| 109 | 91 | } |
| 110 | 92 | |
| 111 | 93 | prepareSandbox { |
| @@ -120,13 +102,14 @@ | ||
| 120 | 102 | prepareSandbox() |
| 121 | 103 | } |
| 122 | 104 | |
| 123 | - wrapper { gradleVersion = properties("gradleVersion").get() } | |
| 105 | + wrapper { | |
| 106 | + gradleVersion = properties("gradleVersion").get() | |
| 107 | + } | |
| 124 | 108 | |
| 125 | 109 | patchPluginXml { |
| 126 | - version.set(properties("pluginVersion")) | |
| 127 | - sinceBuild.set(properties("pluginSinceBuild")) | |
| 128 | - untilBuild.set(properties("pluginUntilBuild")) | |
| 129 | - pluginDescription.set( | |
| 110 | + sinceBuild = properties("pluginSinceBuild") | |
| 111 | + untilBuild = properties("pluginUntilBuild") | |
| 112 | + pluginDescription = | |
| 130 | 113 | providers.fileContents(layout.projectDirectory.file("README.md")).asText.map { |
| 131 | 114 | val start = "<!-- Plugin description -->" |
| 132 | 115 | val end = "<!-- Plugin description end -->" |
| @@ -140,7 +123,6 @@ | ||
| 140 | 123 | subList(indexOf(start) + 1, indexOf(end)).joinToString("\n").let(::markdownToHTML) |
| 141 | 124 | } |
| 142 | 125 | } |
| 143 | - ) | |
| 144 | 126 | } |
| 145 | 127 | |
| 146 | 128 | // Configure UI tests plugin |
| @@ -167,7 +149,7 @@ | ||
| 167 | 149 | // See ContinueExtensionSettingsService.kt for more info. |
| 168 | 150 | // Currently commented out however since test fail in CI with this version |
| 169 | 151 | // intellij { |
| 170 | -// version.set("2024.1") | |
| 152 | +// version = "2024.1" | |
| 171 | 153 | // } |
| 172 | 154 | } |
| 173 | 155 | |
| @@ -178,17 +160,10 @@ | ||
| 178 | 160 | } |
| 179 | 161 | |
| 180 | 162 | publishPlugin { |
| 181 | - // dependsOn("patchChangelog") | |
| 182 | 163 | token = environment("PUBLISH_TOKEN") |
| 183 | - // The pluginVersion is based on the SemVer (https://semver.org) and supports pre-release | |
| 184 | - // labels, like 2.1.7-alpha.3 | |
| 185 | - // Specify pre-release label to publish the plugin in a custom Release Channel automatically. | |
| 186 | - // Read more: | |
| 187 | - // https://plugins.jetbrains.com/docs/intellij/deployment.html#specifying-a-release-channel | |
| 188 | - channels.set(listOf(environment("RELEASE_CHANNEL").getOrElse("eap"))) | |
| 189 | - | |
| 190 | - // We always hide the stable releases until a few days of EAP have proven them stable | |
| 191 | - // hidden = environment("RELEASE_CHANNEL").map { it == "stable" }.getOrElse(false) | |
| 164 | + | |
| 165 | + val channel = if (isEap) "eap" else "default" | |
| 166 | + channels = listOf(channel) | |
| 192 | 167 | } |
| 193 | 168 | |
| 194 | 169 | runIde { |