Skip to content

Commit e817439

Browse files
committed
Fix 1.21.8 ver range & Maven Local Publishing
1 parent 6e295ba commit e817439

File tree

2 files changed

+18
-3
lines changed

2 files changed

+18
-3
lines changed

build.gradle.kts

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ plugins {
77
alias(libs.plugins.blossom)
88
alias(libs.plugins.ksp)
99
alias(libs.plugins.fletchingtable.fabric)
10+
id("maven-publish")
1011
}
1112

1213
repositories {
@@ -53,9 +54,10 @@ val mod = ModData()
5354
val deps = Dependencies()
5455
val loader = LoaderData()
5556

57+
val versionString = "${mod.version}-${mod.minecraftVersion}_${loader.name}"
5658
group = mod.group
57-
base {
58-
archivesName.set("${mod.id}-${mod.version}+${mod.minecraftVersion}-${loader.name}")
59+
base {
60+
archivesName.set("${mod.id}-${versionString}")
5961
}
6062

6163
java {
@@ -193,6 +195,19 @@ tasks {
193195
}
194196
}
195197

198+
publishing {
199+
publications {
200+
create<MavenPublication>("mavenJava") {
201+
artifactId = mod.id
202+
group = project.group
203+
version = versionString
204+
from(components["java"])
205+
}
206+
}
207+
208+
repositories {}
209+
}
210+
196211
if (stonecutter.current.isActive) {
197212
rootProject.tasks.register("buildActive") {
198213
group = "project"

versions/1.21.8-fabric/gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ deps.modmenu_version=15.0.0
66

77
mod.obfuscated=true
88
mod.minecraft_version=1.21.8
9-
mod.minecraft_version_range=1.21.6 1.21.7 1.21.8
9+
mod.minecraft_version_range=>=1.21.6 <=1.21.8

0 commit comments

Comments
 (0)