1
0
mirror of https://github.com/AllanWang/Frost-for-Facebook.git synced 2024-09-19 23:21:34 +02:00
Frost-for-Facebook/buildSrc/build.gradle.kts

37 lines
717 B
Plaintext
Raw Permalink Normal View History

2019-06-07 20:52:55 +02:00
plugins {
`kotlin-dsl`
}
2019-06-07 20:55:59 +02:00
group = "com.pitchedapps"
2019-06-07 20:52:55 +02:00
repositories {
jcenter()
maven("https://jitpack.io")
}
2019-07-03 09:23:24 +02:00
var isRoot = false
2019-06-08 08:10:02 +02:00
// Currently can't read properties from root project
// Reading it manually since it's simple
val rootProps =
2019-07-03 04:59:59 +02:00
File(
2019-07-03 09:23:24 +02:00
project.rootDir.let {
if (it.name == "buildSrc") {
it.parent
} else {
isRoot = true
it.absolutePath
}
},
2019-07-03 04:59:59 +02:00
"gradle.properties"
)
2019-06-08 08:10:02 +02:00
val kau = rootProps.useLines {
it.first { s -> s.startsWith("KAU=") }
}.substring(4).trim()
2019-07-03 09:23:24 +02:00
if (isRoot) {
println("Using kau $kau")
}
2019-06-07 20:52:55 +02:00
dependencies {
2019-06-08 08:10:02 +02:00
implementation("ca.allanwang.kau:gradle-plugin:$kau")
2019-07-03 08:24:22 +02:00
}