From cf00bc82430c87051b5e221664b8c8471f4cf463 Mon Sep 17 00:00:00 2001 From: Alexander Likhachev Date: Sat, 1 May 2021 07:11:25 +0300 Subject: [PATCH] [Build] Remove outdated IDEA sync detection --- .../src/BuildProperties.kt | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/dependencies/kotlin-build-gradle-plugin/src/BuildProperties.kt b/dependencies/kotlin-build-gradle-plugin/src/BuildProperties.kt index 8164ee015a7..271c0874b32 100644 --- a/dependencies/kotlin-build-gradle-plugin/src/BuildProperties.kt +++ b/dependencies/kotlin-build-gradle-plugin/src/BuildProperties.kt @@ -45,20 +45,7 @@ class KotlinBuildProperties( val isJpsBuildEnabled: Boolean = getBoolean("jpsBuild") - val isInIdeaSync: Boolean = run { - // "idea.sync.active" was introduced in 2019.1 - propertiesProvider.getSystemProperty("idea.sync.active")?.toBoolean() == true || let { - // before 2019.1 there is "idea.active" that was true only on sync, - // but since 2019.1 "idea.active" present in task execution too. - // So let's check Idea version - val majorIdeaVersion = propertiesProvider.getSystemProperty("idea.version") - ?.split(".") - ?.getOrNull(0) - val isBeforeIdea2019 = majorIdeaVersion == null || majorIdeaVersion.toInt() < 2019 - - isBeforeIdea2019 && propertiesProvider.getSystemProperty("idea.active")?.toBoolean() == true - } - } + val isInIdeaSync: Boolean = propertiesProvider.getSystemProperty("idea.sync.active")?.toBoolean() == true val isInJpsBuildIdeaSync: Boolean get() = isJpsBuildEnabled && isInIdeaSync