-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle.kts
67 lines (57 loc) · 1.52 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
plugins {
kotlin("jvm") version "2.0.0" // Use the latest stable version of Kotlin
id("org.openjfx.javafxplugin") version "0.1.0" // JavaFX plugin
`maven-publish`
}
group = "io.github.talkarcabbage"
version = "0.17.2"
repositories {
mavenCentral()
maven {
url = uri("https://jitpack.io")
}
}
dependencies {
implementation(kotlin("stdlib"))
implementation("com.google.guava:guava:33.2.1-jre")
implementation("io.github.talkarcabbage:talkarlogger:0.3.0")
testImplementation("org.junit.jupiter:junit-jupiter-api:5.8.1")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:5.8.1")
}
javafx {
version = "22.0.2"
modules = listOf("javafx.controls", "javafx.fxml")
}
sourceSets {
main {
resources {
srcDirs("src/main/resources")
}
}
}
tasks.test {
useJUnitPlatform()
}
tasks.withType<Jar> {
manifest {
attributes["Main-Class"] = "io.github.talkarcabbage.rstimer.FXController"
}
// This block includes all dependencies in the JAR
from(sourceSets.main.get().output)
dependsOn(configurations.runtimeClasspath)
from({
configurations.runtimeClasspath.get().filter { it.name.endsWith("jar") }.map { zipTree(it) }
})
// Ensure CSS and image files are included
from("src/css") {
into("css")
}
from("src/images") {
into("images")
}
from("src/fxml") {
into("fxml")
}
// Avoid duplicate files in the JAR
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
}