Files
AstraContent/build.gradle.kts
T

23 lines
1.2 KiB
Kotlin
Raw Normal View History

plugins { java; id("net.neoforged.moddev") version "2.0.146" }
group = "online.astradev"
version = "0.2.0"
repositories { mavenCentral() }
dependencies {
testImplementation("org.junit.jupiter:junit-jupiter:5.11.4")
testRuntimeOnly("org.junit.platform:junit-platform-launcher:1.11.4")
}
neoForge {
version = "26.2.0.79"
mods { create("astracontent") { sourceSet(sourceSets.main.get()) } }
}
java { toolchain.languageVersion.set(JavaLanguageVersion.of(25)); withSourcesJar() }
tasks.withType<JavaCompile>().configureEach { options.encoding = "UTF-8"; options.release.set(25) }
tasks.processResources { filesMatching("META-INF/neoforge.mods.toml") { expand("version" to project.version) } }
tasks.test { useJUnitPlatform() }
sourceSets.test { compileClasspath += sourceSets.main.get().compileClasspath; runtimeClasspath += sourceSets.main.get().compileClasspath }
val verification = sourceSets.create("verification") {
compileClasspath += sourceSets.main.get().output + sourceSets.main.get().compileClasspath
runtimeClasspath += output + compileClasspath
}
tasks.register<Jar>("verificationJar") { from(verification.output); archiveClassifier.set("verification") }