-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.gradle.kts
64 lines (55 loc) · 1.66 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
plugins {
kotlin("jvm") version "2.0.0-Beta3"
id("io.gitlab.arturbosch.detekt")
idea
application
}
dependencies {
implementation(kotlin("stdlib"))
implementation(kotlin("reflect"))
implementation(KotlinX.coroutines.core)
implementation("ch.qos.logback:logback-classic:_")
implementation("com.soywiz.korlibs.korio:korio:_")
implementation("com.soywiz.korlibs.korim:korim:_")
implementation("com.github.ajalt.clikt:clikt:_")
implementation("io.github.classgraph:classgraph:_")
testImplementation(Testing.kotest.runner.junit5)
testImplementation(Testing.kotest.assertions.core)
}
repositories {
mavenCentral()
}
kotlin {
jvmToolchain(21)
sourceSets["main"].kotlin.srcDir("src/commonMain/kotlin")
sourceSets["main"].kotlin.srcDir("src/jvmMain/kotlin")
sourceSets["main"].kotlin.srcDir("src/examples/kotlin")
sourceSets["test"].kotlin.srcDir("src/commonTest/kotlin")
sourceSets["test"].kotlin.srcDir("src/jvmTest/kotlin")
}
tasks.test {
useJUnitPlatform()
}
task<JavaExec>("commandline") {
mainClass.set("MainKt")
classpath = sourceSets["main"].runtimeClasspath
args = listOf("World10.kt", "build/World10.png")
}
task<JavaExec>("swing") {
mainClass.set("net.dinkla.raytracer.ui.swing.FromTheGroundUpRayTracerKt")
classpath = sourceSets["main"].runtimeClasspath
}
application {
mainClass.set("net.dinkla.raytracer.MainKt")
}
detekt {
config.setFrom("detekt-config.yml")
source.setFrom(
"src/main/java",
"src/main/kotlin",
"src/commonMain/kotlin",
"src/jvmMain/kotlin",
"src/commonTest/kotlin",
"src/jvmTest/kotlin",
)
}