mirror of
https://github.com/chenasraf/pantry-flutter.git
synced 2026-05-17 17:28:03 +00:00
43 lines
1.3 KiB
Plaintext
43 lines
1.3 KiB
Plaintext
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)
|
|
}
|
|
subprojects {
|
|
project.evaluationDependsOn(":app")
|
|
|
|
// Force any Flutter plugin subproject (e.g. receive_sharing_intent)
|
|
// that defaults to a different Kotlin jvmTarget to match this app's
|
|
// Java/Kotlin compatibility, avoiding "Inconsistent JVM Target
|
|
// Compatibility Between Java and Kotlin Tasks" build failures.
|
|
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinJvmCompile>().configureEach {
|
|
compilerOptions {
|
|
jvmTarget.set(org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_17)
|
|
}
|
|
}
|
|
plugins.withId("com.android.library") {
|
|
extensions.configure<com.android.build.gradle.LibraryExtension>("android") {
|
|
compileOptions {
|
|
sourceCompatibility = JavaVersion.VERSION_17
|
|
targetCompatibility = JavaVersion.VERSION_17
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
tasks.register<Delete>("clean") {
|
|
delete(rootProject.layout.buildDirectory)
|
|
}
|