-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle.kts
116 lines (95 loc) · 3.92 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
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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
import io.github.gradlenexus.publishplugin.shadow.retrofit2.KotlinExtensions
import org.jetbrains.kotlin.gradle.dsl.kotlinExtension
plugins {
alias(libs.plugins.kotlin.jvm) apply false
alias(libs.plugins.nexus.publish)
alias(libs.plugins.git.version)
alias(libs.plugins.dependency.submission)
alias(libs.plugins.validate.poms) apply false
alias(libs.plugins.dokka) apply false
}
group = "io.freefair"
nexusPublishing {
repositories {
sonatype {
stagingProfileId = "7e6204597a774f"
}
}
}
subprojects {
apply(plugin = "org.jetbrains.kotlin.jvm")
apply(plugin = "org.jetbrains.dokka")
group = "io.freefair.ksp"
version = rootProject.version
repositories {
mavenCentral()
}
afterEvaluate {
dependencies {}
}
plugins.withId("maven-publish") {
project.apply(plugin = "signing")
project.apply(plugin = "io.freefair.maven-central.validate-poms")
extensions.getByType(SigningExtension::class.java).apply {
isRequired = !version.toString().endsWith("SNAPSHOT") && gradle.taskGraph.hasTask("publish")
val signingKey = findProperty("signingKey") as String?
val signingPassword = findProperty("signingPassword") as String?
useInMemoryPgpKeys(signingKey, signingPassword)
}
extensions.getByType(PublishingExtension::class.java).apply {
val dokkaHtml by tasks.getting(org.jetbrains.dokka.gradle.DokkaTask::class)
val javadocJar: TaskProvider<Jar> by tasks.registering(Jar::class) {
dependsOn(dokkaHtml)
archiveClassifier.set("javadoc")
from(dokkaHtml.outputDirectory)
}
publications.withType<MavenPublication>().configureEach {
artifact(javadocJar)
artifact(tasks.named("kotlinSourcesJar"))
pom {
url.set("https://github.com/freefair/ksp-processors")
name.set(provider { project.description })
description.set(provider { project.description })
inceptionYear.set("2024")
licenses {
license {
name.set("MIT")
url.set("https://github.com/freefair/ksp-processors/blob/main/LICENSE")
}
}
organization {
name.set("FreeFair")
url.set("https://github.com/freefair")
}
developers {
developer {
id.set("larsgrefer")
name.set("Lars Grefer")
email.set("github@larsgrefer.de")
timezone.set("Europe/Berlin")
}
developer {
id.set("frisch12")
name.set("Dennis Fricke")
email.set("dennis.fricke@freefair.io")
timezone.set("Europe/Berlin")
}
}
ciManagement {
system.set("GitHub Actions")
url.set("https://github.com/freefair/ksp-processors/actions")
}
issueManagement {
system.set("GitHub Issues")
url.set("https://github.com/freefair/ksp-processors/issues")
}
scm {
connection.set("scm:git:https://github.com/freefair/ksp-processors.git")
developerConnection.set("scm:git:git@github.com:freefair/ksp-processors.git")
url.set("https://github.com/freefair/ksp-processors")
}
}
}
}
}
}