-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle.kts
102 lines (82 loc) · 2.75 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
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
kotlin("jvm") version "1.6.21"
kotlin("plugin.serialization") version "1.6.21"
jacoco
application
`maven-publish`
}
group = "id.walt"
version = "1.22.0"
repositories {
mavenCentral()
maven("https://maven.walt.id/repository/waltid/")
}
dependencies {
/* JSON */
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json:1.3.2")
implementation("com.github.victools:jsonschema-generator:4.24.2")
implementation("com.networknt:json-schema-validator:1.0.69")
implementation("net.pwall.json:json-kotlin-schema:0.34")
implementation("com.beust:klaxon:5.6")
/* Logging */
//ANDROID PORT
//implementation("org.lighthousegames:logging-jvm:1.2.0")
//ANDROID PORT
implementation("org.slf4j:slf4j-simple:1.7.36")
/* Kotlin */
// Reflection
implementation("org.jetbrains.kotlin:kotlin-reflect:1.6.21")
// Kotlin
implementation("org.jetbrains.kotlin:kotlin-stdlib:1.6.21")
/* JWT */
implementation("com.nimbusds:nimbus-jose-jwt:9.22")
/* Testing */
testImplementation("io.kotest:kotest-runner-junit5:5.3.0")
testImplementation("io.kotest:kotest-assertions-core:5.3.0")
testImplementation("io.kotest:kotest-assertions-json:5.3.0")
}
tasks.withType<Test> {
useJUnitPlatform()
}
publishing {
publications {
create<MavenPublication>("mavenJava") {
pom {
name.set("waltid-ssikit-vclib")
description.set("Typesafe implementation of W3C Verifiable Credentials in order to facilitate interoperability among various applications.")
url.set("https://walt.id")
}
from(components["java"])
}
}
repositories {
maven {
url = uri("https://maven.walt.id/repository/waltid-ssi-kit/")
val usernameFile = File("secret_maven_username.txt")
val passwordFile = File("secret_maven_password.txt")
val secretMavenUsername = System.getenv()["SECRET_MAVEN_USERNAME"] ?: if (usernameFile.isFile) { usernameFile.readLines()[0] } else { "" }
val secretMavenPassword = System.getenv()["SECRET_MAVEN_PASSWORD"] ?: if (passwordFile.isFile) { passwordFile.readLines()[0] } else { "" }
credentials {
username = secretMavenUsername
password = secretMavenPassword
}
}
}
}
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(16))
}
}
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
//ANDROID PORT
kotlinOptions.jvmTarget = "11"
//ANDROID PORT
}
jacoco.toolVersion = "0.8.8"
tasks.jacocoTestReport {
reports {
xml.required.set(true)
}
}