Migrate AstraSoups to NeoForge as AstraCauldron

This commit is contained in:
2026-09-08 19:44:45 +03:00
parent 8391dfe739
commit a82c2aa0f9
52 changed files with 2095 additions and 2010 deletions
+34 -19
View File
@@ -1,28 +1,43 @@
plugins { java }
group = "online.astradev"
version = "0.1.3"
repositories {
mavenCentral()
maven { url = uri("https://repo.papermc.io/repository/maven-public/") }
plugins {
java
id("net.neoforged.moddev") version "2.0.146"
}
group = "online.astradev"
version = "0.2.0"
repositories { mavenCentral() }
val astraPlusApi = providers.gradleProperty("astraPlusApi")
.orElse("../AstraPlus/build/libs/AstraPlus-0.5.1-api.jar")
dependencies {
compileOnly("io.papermc.paper:paper-api:26.2.build.121-stable")
testImplementation("io.papermc.paper:paper-api:26.2.build.121-stable")
compileOnly(files(astraPlusApi))
testImplementation("org.junit.jupiter:junit-jupiter:5.11.4")
testRuntimeOnly("org.junit.platform:junit-platform-launcher:1.11.4")
}
java { toolchain.languageVersion.set(JavaLanguageVersion.of(26)) }
tasks.withType<JavaCompile>().configureEach { options.encoding = "UTF-8"; options.release.set(25) }
neoForge {
version = "26.2.0.79"
mods { create("astracauldron") { 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 {
inputs.property("pluginVersion", project.version)
filesMatching("plugin.yml") { expand("version" to project.version) }
inputs.property("modVersion", project.version)
filesMatching("META-INF/neoforge.mods.toml") { expand("version" to project.version) }
}
tasks.test { useJUnitPlatform() }
val smoke = sourceSets.create("smoke") {
java.srcDir("tools/smoke")
resources.srcDir("tools/smoke-resources")
compileClasspath += sourceSets.main.get().compileClasspath + sourceSets.main.get().output
compileClasspath += files("../../26.2 Paper/versions/26.2/paper-26.2.jar")
compileClasspath += fileTree("../../26.2 Paper/libraries") { include("**/*.jar") }
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")
}
tasks.register<Jar>("smokeJar") { archiveFileName.set("SoupSmokeTest.jar"); from(smoke.output) }