2020-06-10 19:16:11 +00:00
|
|
|
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
|
|
|
|
|
|
|
plugins {
|
2023-07-29 15:11:08 +00:00
|
|
|
alias(libs.plugins.ktlint)
|
2020-06-10 19:16:11 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
buildscript {
|
|
|
|
repositories {
|
|
|
|
google()
|
2020-10-18 02:57:22 +00:00
|
|
|
gradlePluginPortal()
|
2020-06-10 19:16:11 +00:00
|
|
|
}
|
|
|
|
dependencies {
|
2023-07-29 15:11:08 +00:00
|
|
|
classpath(libs.android.plugin)
|
|
|
|
classpath(libs.kotlin.gradle.plugin)
|
|
|
|
classpath(libs.google.services)
|
|
|
|
classpath(libs.firebase.appdistribution.gradle)
|
|
|
|
classpath(libs.android.junit5)
|
|
|
|
classpath(libs.play.publisher)
|
|
|
|
classpath(libs.hilt.android.gradle.plugin)
|
2020-06-10 19:16:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
allprojects {
|
2020-06-11 17:15:50 +00:00
|
|
|
apply(plugin = "org.jlleitschuh.gradle.ktlint")
|
|
|
|
|
2020-06-10 19:16:11 +00:00
|
|
|
tasks.withType<KotlinCompile>().configureEach {
|
|
|
|
kotlinOptions {
|
2021-08-07 01:41:30 +00:00
|
|
|
jvmTarget = "11"
|
2020-06-10 19:16:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2021-10-14 03:46:49 +00:00
|
|
|
gradle.projectsEvaluated {
|
|
|
|
project(":app").tasks.matching { it.name.startsWith("publish") }.configureEach {
|
|
|
|
mustRunAfter(project(":wear").tasks.matching { it.name.startsWith("publish") })
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-06-10 19:16:11 +00:00
|
|
|
tasks.register("clean").configure {
|
|
|
|
delete("build")
|
|
|
|
}
|
|
|
|
|
|
|
|
ktlint {
|
|
|
|
android.set(true)
|
|
|
|
}
|
2023-06-26 13:05:17 +00:00
|
|
|
|
|
|
|
tasks.register("versionFile").configure {
|
|
|
|
group = "publishing"
|
|
|
|
doLast {
|
|
|
|
File(projectDir, "version.txt").writeText(project.version.toString())
|
|
|
|
}
|
|
|
|
}
|