2023-10-27 01:33:00 -06:00
|
|
|
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
|
|
|
|
|
|
|
|
val zircon_version: String by project
|
|
|
|
val slf4j_version: String by project
|
|
|
|
val junit_version: String by project
|
|
|
|
val mockito_version: String by project
|
|
|
|
val assertj_version: String by project
|
2023-10-28 14:24:38 -06:00
|
|
|
val game_name: String by project
|
|
|
|
val version: String by project
|
2023-10-27 01:33:00 -06:00
|
|
|
|
|
|
|
plugins {
|
2023-10-28 14:24:38 -06:00
|
|
|
kotlin("jvm") version "1.9.10"
|
|
|
|
id("com.github.johnrengelman.shadow") version "8.1.1"
|
2023-10-27 01:33:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenLocal()
|
|
|
|
mavenCentral()
|
|
|
|
jcenter()
|
|
|
|
}
|
|
|
|
|
|
|
|
java {
|
2023-10-28 14:24:38 -06:00
|
|
|
sourceCompatibility = JavaVersion.VERSION_20
|
|
|
|
targetCompatibility = JavaVersion.VERSION_20
|
2023-10-27 01:33:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
implementation("org.slf4j:slf4j-api:$slf4j_version")
|
|
|
|
implementation("org.slf4j:slf4j-simple:$slf4j_version")
|
|
|
|
|
|
|
|
implementation("org.hexworks.zircon:zircon.core-jvm:$zircon_version")
|
|
|
|
implementation("org.hexworks.zircon:zircon.jvm.swing:$zircon_version")
|
|
|
|
|
|
|
|
implementation(kotlin("stdlib-jdk8"))
|
|
|
|
|
|
|
|
testImplementation("junit:junit:$junit_version")
|
|
|
|
testImplementation("org.mockito:mockito-all:$mockito_version")
|
|
|
|
testImplementation("org.assertj:assertj-core:$assertj_version")
|
|
|
|
}
|
|
|
|
|
|
|
|
tasks {
|
|
|
|
named<ShadowJar>("shadowJar") {
|
2023-10-28 14:24:38 -06:00
|
|
|
archiveBaseName.set("$game_name + $version")
|
2023-10-27 01:33:00 -06:00
|
|
|
mergeServiceFiles()
|
|
|
|
manifest {
|
2023-10-28 14:24:38 -06:00
|
|
|
attributes(mapOf("Main-Class" to "group.ouroboros.potrogue.MainKt"))
|
2023-10-27 01:33:00 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
tasks {
|
|
|
|
build {
|
|
|
|
dependsOn(shadowJar)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
val jar by tasks.getting(Jar::class) {
|
|
|
|
manifest {
|
2023-10-28 14:24:38 -06:00
|
|
|
attributes["Main-Class"] = "group.ouroboros.potrogue.MainKt"
|
2023-10-27 01:33:00 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|