mirror of
https://github.com/T8RIN/ImageToolbox.git
synced 2025-05-17 13:35:58 +08:00
unified dependecies with jvmTarget
This commit is contained in:
@ -102,8 +102,8 @@ android {
|
||||
}
|
||||
}
|
||||
compileOptions {
|
||||
sourceCompatibility = rootProject.extra.get("javaCompile") as JavaVersion
|
||||
targetCompatibility = rootProject.extra.get("javaCompile") as JavaVersion
|
||||
sourceCompatibility = JavaVersion.toVersion(libs.versions.jvmTarget.get())
|
||||
targetCompatibility = JavaVersion.toVersion(libs.versions.jvmTarget.get())
|
||||
isCoreLibraryDesugaringEnabled = true
|
||||
}
|
||||
|
||||
|
@ -18,8 +18,8 @@ android {
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility = rootProject.extra.get("javaCompile") as JavaVersion
|
||||
targetCompatibility = rootProject.extra.get("javaCompile") as JavaVersion
|
||||
sourceCompatibility = JavaVersion.toVersion(libs.versions.jvmTarget.get())
|
||||
targetCompatibility = JavaVersion.toVersion(libs.versions.jvmTarget.get())
|
||||
}
|
||||
|
||||
kotlinOptions {
|
||||
|
@ -31,8 +31,10 @@ internal fun Project.configureKotlinAndroid(
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility = JavaVersion.VERSION_17
|
||||
targetCompatibility = JavaVersion.VERSION_17
|
||||
sourceCompatibility =
|
||||
JavaVersion.toVersion(libs.findVersion("jvmTarget").get().toString())
|
||||
targetCompatibility =
|
||||
JavaVersion.toVersion(libs.findVersion("jvmTarget").get().toString())
|
||||
isCoreLibraryDesugaringEnabled = true
|
||||
}
|
||||
|
||||
@ -61,13 +63,13 @@ internal fun Project.configureKotlinAndroid(
|
||||
"-opt-in=androidx.compose.ui.unit.ExperimentalUnitApi",
|
||||
"-opt-in=kotlinx.coroutines.ExperimentalCoroutinesApi",
|
||||
)
|
||||
jvmTarget = JavaVersion.VERSION_17.toString()
|
||||
jvmTarget = libs.findVersion("jvmTarget").get().toString()
|
||||
}
|
||||
}
|
||||
|
||||
tasks.withType<KotlinCompile>().configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = JavaVersion.VERSION_17.toString()
|
||||
jvmTarget = libs.findVersion("jvmTarget").get().toString()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,8 +1,4 @@
|
||||
buildscript {
|
||||
rootProject.extra.apply {
|
||||
set("javaCompile", JavaVersion.VERSION_17)
|
||||
}
|
||||
|
||||
repositories {
|
||||
gradlePluginPortal()
|
||||
google()
|
||||
|
Reference in New Issue
Block a user