-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle
77 lines (65 loc) · 2.13 KB
/
build.gradle
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
import org.jetbrains.dokka.gradle.DokkaTask
buildscript {
repositories {
google()
mavenCentral()
}
dependencies {
classpath libs.android.gradle.plugin
}
}
plugins {
alias libs.plugins.nexus.publish
alias libs.plugins.dokka
alias libs.plugins.kt.lint
alias libs.plugins.kotlin.android apply false
alias libs.plugins.paparazzi apply false
}
allprojects {
repositories {
google()
mavenCentral()
// Needed for some automated and manual testing (e.g: acceptance tests)
mavenLocal()
}
}
subprojects {
apply plugin: 'org.jlleitschuh.gradle.ktlint'
repositories {
mavenCentral()
}
ktlint {
outputToConsole.set(true)
debug.set(true)
android.set(true)
}
}
subprojects {
// This is setup of Dokka. It is used for generating API docs web page from in-doc comments
// See official Dokka docs for more information: https://kotlin.github.io/dokka/
apply plugin: 'org.jetbrains.dokka'
tasks.withType(DokkaTask).configureEach {
String currentYear = Calendar.getInstance().get(Calendar.YEAR)
String gliaSvgLogoPath = rootProject.file("dokkaAssets/logo-icon.svg")
// These configurations currently apply only to dokkaHtml and not to dokkaJavadoc.
// Have not found how to solve this. But at current Dokka version (1.9.20)
// Javadoc plugin is still in 'early stages' of development.
String configurationJson = $/{
"footerMessage": "(c) ${currentYear} Glia Technologies, Inc. All rights reserved.",
"customAssets": ["${gliaSvgLogoPath}"]
}/$
pluginsMapConfiguration.set(["org.jetbrains.dokka.base.DokkaBase": configurationJson])
moduleName = "Glia Android Widgets SDK"
suppressInheritedMembers.set(true)
}
// This adds support for @hide keyword inside in-code docs
// For some reason artifact ID mentioned in docs does not exist, probably a typo. This one has slightly different order of words
dependencies {
dokkaPlugin(libs.java.dokka)
}
}
tasks.register('clean', Delete) {
delete rootProject.layout.buildDirectory
}
apply from: "${rootDir}/scripts/publish-settings.gradle"
apply from: "${rootDir}/scripts/version-updater.gradle"