-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.gradle.kts
81 lines (67 loc) · 1.57 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
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
plugins {
id("java")
alias(libs.plugins.shadow)
alias(libs.plugins.fabricJavaGenerator)
alias(libs.plugins.sonatypeCentralPortalPublisher)
}
group = "dev.strela"
version = "0.0.2"
repositories {
mavenCentral()
}
dependencies {
implementation(libs.bundles.fabricKubernetes)
}
tasks.named("shadowJar", ShadowJar::class) {
mergeServiceFiles()
archiveFileName.set("${project.name}.jar")
}
javaGen {
source = file("src/main/resources/kubernetes")
}
sourceSets {
main {
java {
srcDirs("build/generated/sources/dev/strela/v1")
}
}
}
tasks.withType<Javadoc> {
source = files(source).minus(fileTree("build/generated/sources")).asFileTree
}
centralPortal {
username = project.findProperty("sonatypeUsername") as String
password = project.findProperty("sonatypePassword") as String
pom {
name.set("Strela Java SDK")
description.set("A Java SDK for Strela")
url.set("https://github.com/strela-dev/java-sdk")
developers {
developer {
id.set("fllipeis")
email.set("[email protected]")
}
}
licenses {
license {
name.set("Apache-2.0")
url.set("https://www.apache.org/licenses/LICENSE-2.0.txt")
}
}
scm {
url.set("https://github.com/strela-dev/java-sdk.git")
connection.set("git:[email protected]:strela-dev/java-sdk.git")
}
}
}
signing {
useGpgCmd()
sign(configurations.archives.get())
}
java {
toolchain.languageVersion.set(JavaLanguageVersion.of(21))
}
tasks.test {
useJUnitPlatform()
}