Set explicit lang version 1.3 for kotlin-native-utils & kotlin-util-io
Without explicit version we cannot use those modules in buildscripts with Gradle 6.8+ because Gradle doesn't set flag `skipPrereleaseCheck` (previously was named `skipMetadataVersionCheck`). This way we make it compatible with all supported versions of Gradle.
This commit is contained in:
@@ -15,6 +15,13 @@ sourceSets {
|
||||
"test" { projectDefault() }
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
|
||||
kotlinOptions.languageVersion = "1.3"
|
||||
kotlinOptions.apiVersion = "1.3"
|
||||
}
|
||||
}
|
||||
|
||||
publish()
|
||||
|
||||
standardPublicJars()
|
||||
|
||||
@@ -19,6 +19,13 @@ sourceSets {
|
||||
"test" { projectDefault() }
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
|
||||
kotlinOptions.languageVersion = "1.3"
|
||||
kotlinOptions.apiVersion = "1.3"
|
||||
}
|
||||
}
|
||||
|
||||
// TODO: this single known external consumer of this artifact is Kotlin/Native backend,
|
||||
// so publishing could be stopped after migration to monorepo
|
||||
publish()
|
||||
|
||||
@@ -5,8 +5,6 @@
|
||||
|
||||
package org.jetbrains.kotlin.konan.target
|
||||
|
||||
import java.util.*
|
||||
|
||||
/**
|
||||
* Name of a preset used in the 'kotlin-multiplatform' Gradle plugin to represent this target.
|
||||
*/
|
||||
@@ -21,5 +19,5 @@ val KonanTarget.presetName: String
|
||||
|
||||
private fun evaluatePresetName(targetName: String): String {
|
||||
val nameParts = targetName.split('_').mapNotNull { it.takeIf(String::isNotEmpty) }
|
||||
return nameParts.asSequence().drop(1).joinToString("", nameParts.firstOrNull().orEmpty()) { it.capitalize(Locale.US) }
|
||||
return nameParts.asSequence().drop(1).joinToString("", nameParts.firstOrNull().orEmpty()) { it.capitalize() }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user