Skip to content

Commit 8174e44

Browse files
committed
set dev build in the mod json
1 parent 23fbc79 commit 8174e44

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

build.gradle.kts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ val kotlinFabricVersion: String by project
1111

1212
val replacements = file("gradle.properties").inputStream().use { stream ->
1313
Properties().apply { load(stream) }
14-
}.map { (k, v) -> k.toString() to v.toString() }.toMap()
14+
}.map { (k, v) -> k.toString() to v.toString() }.toMap().toMutableMap()
1515

1616
plugins {
1717
kotlin("jvm") version "2.3.0"
@@ -27,6 +27,7 @@ version = if (isDevBuild && buildNum != null) {
2727
} else {
2828
project.property("modVersion") as String
2929
}
30+
replacements["modVersion"] = version.toString()
3031
group = project.property("mavenGroup") as String
3132
base.archivesName = modId
3233

@@ -49,6 +50,7 @@ tasks {
4950
}
5051

5152
processResources {
53+
inputs.properties(replacements)
5254
filesMatching("fabric.mod.json") { expand(replacements) }
5355

5456
// Forces the task to always run

0 commit comments

Comments
 (0)