-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle.kts
104 lines (85 loc) · 2.74 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
var fileName = "ServiceHelper"
plugins {
java
application
id("org.jetbrains.kotlin.jvm") version "1.6.10"
id("org.jetbrains.kotlin.plugin.serialization") version "1.6.10"
id("org.openjfx.javafxplugin") version "0.0.7"
id("edu.sc.seis.launch4j") version "2.4.6"
}
group = "com.likco"
version = "1.0"
val spaceUsername: String by project
val spacePassword: String by project
repositories {
mavenCentral()
maven { url = uri("https://jitpack.io") }
maven {
url = uri("https://maven.pkg.jetbrains.space/likco/p/dbhelper/maven")
credentials {
username = spaceUsername
password = spacePassword
}
}
}
dependencies {
implementation("no.tornado:tornadofx:1.7.20")
implementation("com.ibm.icu:icu4j:70.1")
implementation("com.google.code.gson:gson:2.9.0")
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json:1.3.2")
implementation("com.squareup.moshi:moshi-kotlin:1.13.0")
implementation("com.beust:klaxon:5.5")
implementation("org.jsoup:jsoup:1.14.3")
implementation("org.apache.poi", "poi", "5.0.0")
implementation("org.apache.poi", "poi-ooxml", "5.0.0")
implementation("it.sauronsoftware:junique:1.0.4")
implementation("liklibs.db:db-helper:0.9.2")
implementation(kotlin("stdlib-jdk8"))
testImplementation(kotlin("reflect"))
testImplementation(kotlin("test"))
implementation(kotlin("reflect"))
}
javafx {
modules = listOf("javafx.controls", "javafx.fxml")
version = "17.0.2"
}
tasks.test {
useJUnitPlatform()
}
launch4j {
jreMinVersion = "1.0.0"
headerType = "gui"
mainClassName = "ldcapps.servicehelper.LauncherKt"
outfile = "$fileName.exe"
jar = "../libs/$fileName.jar"
}
tasks.compileJava {
options.isIncremental = true
options.isFork = true
options.isFailOnError = false
options.release.set(16)
}
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(16))
}
}
tasks.jar {
duplicatesStrategy = DuplicatesStrategy.INCLUDE
from(sourceSets.main.get().output)
archiveName = "$fileName.jar"
dependsOn(configurations.runtimeClasspath)
manifest {
duplicatesStrategy = DuplicatesStrategy.INCLUDE
exclude("META-INF/*.SF", "META-INF/*.DSA", "META-INF/*.RSA", "META-INF/*.MF, META-INF/LICENSE")
attributes(
"Implementation-Title" to "ServiceHelper",
"Implementation-Version" to archiveVersion,
"Main-Class" to "ldcapps.servicehelper.LauncherKt",
"Class-Path" to configurations.runtimeClasspath.files.joinToString(" ") { "lib/$it.name" }
)
}
from({
configurations.runtimeClasspath.get().filter { it.name.endsWith("jar") }.map { zipTree(it) }
})
}