37 lines
1.1 KiB
Kotlin
37 lines
1.1 KiB
Kotlin
allprojects {
|
|
repositories {
|
|
google()
|
|
mavenCentral()
|
|
}
|
|
}
|
|
|
|
val newBuildDir: Directory =
|
|
rootProject.layout.buildDirectory
|
|
.dir("../../build")
|
|
.get()
|
|
rootProject.layout.buildDirectory.value(newBuildDir)
|
|
|
|
subprojects {
|
|
val newSubprojectBuildDir: Directory = newBuildDir.dir(project.name)
|
|
project.layout.buildDirectory.value(newSubprojectBuildDir)
|
|
|
|
// mobile_scanner 7.2.1 detects AGP 9, while Flutter currently opts this
|
|
// project out of AGP's built-in Kotlin support. Apply the legacy Kotlin
|
|
// plugin explicitly so the package's Kotlin DSL remains available.
|
|
if (name in setOf("file_picker", "mobile_scanner", "nfc_manager")) {
|
|
pluginManager.apply("org.jetbrains.kotlin.android")
|
|
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach {
|
|
compilerOptions.jvmTarget.set(
|
|
org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_17
|
|
)
|
|
}
|
|
}
|
|
}
|
|
subprojects {
|
|
project.evaluationDependsOn(":app")
|
|
}
|
|
|
|
tasks.register<Delete>("clean") {
|
|
delete(rootProject.layout.buildDirectory)
|
|
}
|