-
Notifications
You must be signed in to change notification settings - Fork 28
Expand file tree
/
Copy pathbuild.gradle.kts
More file actions
81 lines (68 loc) · 2.04 KB
/
build.gradle.kts
File metadata and controls
81 lines (68 loc) · 2.04 KB
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
plugins {
`java-library`
`maven-publish`
signing
id("org.owasp.dependencycheck") version "9.2.0"
id("org.jreleaser") version "1.13.1"
}
group = "com.chargebee"
version = "4.5.0"
description = "Java client library for ChargeBee"
// Project metadata
val projectUrl = "https://github.com/chargebee/chargebee-java"
val projectLicense = "MIT License"
val projectLicenseUrl = "https://opensource.org/licenses/MIT"
// Team details (stored as maps for use in publish.gradle.kts)
val teamMembers = listOf(
mapOf(
"id" to "dx",
"name" to "DX Team",
"email" to "dx@chargebee.com",
"timezone" to "+5:30"
)
)
extra["projectUrl"] = projectUrl
extra["projectLicense"] = projectLicense
extra["projectLicenseUrl"] = projectLicenseUrl
extra["teamMembers"] = teamMembers
java {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
withSourcesJar()
withJavadocJar()
}
repositories {
mavenCentral()
}
dependencies {
implementation("com.google.code.gson:gson:2.13.2")
testImplementation("org.junit.jupiter:junit-jupiter:5.13.0")
testRuntimeOnly("org.junit.platform:junit-platform-launcher")
testImplementation("org.mockito:mockito-core:4.11.0")
}
tasks.withType<JavaCompile> {
options.encoding = "UTF-8"
}
// Relax javadoc strictness for beta builds
tasks.withType<Javadoc> {
// Disable doclint to avoid failing on minor doc issues
(options as StandardJavadocDocletOptions).addStringOption("Xdoclint:none", "-quiet")
isFailOnError = false
}
tasks.test {
useJUnitPlatform()
}
tasks.processResources {
filesMatching("**/version.properties") {
expand(mapOf("version" to project.version))
}
}
// OWASP Dependency Check configuration
dependencyCheck {
format = org.owasp.dependencycheck.reporting.ReportGenerator.Format.ALL.toString()
analyzedTypes = listOf("jar")
suppressionFile = "owasp-suppression.xml"
failBuildOnCVSS = 7.0f
}
// Apply publishing and deployment configuration
apply(from = "publish.gradle.kts")