generated from lcdsmao/kotlin-android-library-template
-
Notifications
You must be signed in to change notification settings - Fork 3
/
build.gradle.kts
40 lines (34 loc) · 916 Bytes
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
import com.vanniktech.maven.publish.SonatypeHost
import org.jetbrains.kotlin.konan.properties.loadProperties
plugins {
`detekt-config`
id("org.jetbrains.dokka")
id("com.vanniktech.maven.publish")
}
allprojects {
repositories {
google()
mavenCentral()
}
}
subprojects {
val signingPropsFile = file("$rootDir/release/signing.properties")
.takeIf { it.exists() } ?: return@subprojects
loadProperties(signingPropsFile.path).forEach { (key, value) ->
extra[key as String] = when (key) {
"signing.secretKeyRingFile" -> {
// If this is the key ring, treat it as a relative path
rootProject.file(value).absolutePath
}
else -> value
}
}
plugins.withId("com.vanniktech.maven.publish") {
mavenPublish {
sonatypeHost = SonatypeHost.S01
}
}
}
tasks.dokkaHtmlMultiModule.configure {
outputDirectory.set(rootDir.resolve("docs/api"))
}