-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathbuild.gradle.kts
39 lines (30 loc) · 1.31 KB
/
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
allprojects {
this.group = "org.kotools"
this.repositories.mavenCentral()
}
// ---------------------------------- Plugins ----------------------------------
plugins {
this.alias(libs.plugins.kotlin.multiplatform) apply false
this.alias(libs.plugins.dokka)
this.alias(libs.plugins.kotools.types.documentation)
}
// ----------------------------- Plugin extensions -----------------------------
documentation.moduleName = "Kotools Types"
// ------------------------------- Dependencies --------------------------------
dependencies.dokkaHtmlMultiModulePlugin(libs.dokka.versioning)
// ----------------------------------- Tasks -----------------------------------
tasks.register("checkAll").configure {
this.description = "Checks all projects."
this.group = "verification"
this.project.subprojects.mapNotNull { it?.tasks?.findByName("check") }
.let(this::setDependsOn)
}
tasks.register<Exec>("tag").configure {
this.description = "Creates a Git annotated tag for the current version."
this.group = "release"
val gitmoji = "\uD83D\uDD16"
val moduleName: String = documentation.moduleName.get()
val version: String = this.project.version.toString()
val tagMessage = "$gitmoji $moduleName $version"
this.setCommandLine("git", "tag", version, "-s", "-m", tagMessage)
}