Skip to content

Commit

Permalink
Bump to BETA 4, fix auto update tool
Browse files Browse the repository at this point in the history
  • Loading branch information
Harleyoc1 committed Jul 18, 2023
1 parent c5464b7 commit 8c8caee
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 6 deletions.
15 changes: 11 additions & 4 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ plugins {
id("com.harleyoconnor.translationsheet") version "0.1.1"
id("com.matthewprenger.cursegradle") version "1.4.0"
id("com.modrinth.minotaur") version "2.+"
id("com.harleyoconnor.autoupdatetool") version "1.0.0"
id("com.harleyoconnor.autoupdatetool") version "1.+"
}

repositories {
Expand Down Expand Up @@ -175,7 +175,9 @@ modrinth {
versionType.set(optionalProperty("versionType") ?: "release")
uploadFile.set(tasks.jar.get())
gameVersions.add(mcVersion)
changelog.set(changelogFile.readText())
if (changelogFile.exists()) {
changelog.set(changelogFile.readText())
}
}

tasks.withType<GenerateModuleMetadata> {
Expand Down Expand Up @@ -254,15 +256,20 @@ tasks.register("publishToAllPlatforms") {
this.dependsOn("publishMavenJavaPublicationToHarleyOConnorRepository", "curseforge")
}

val minecraftVersion = mcVersion

autoUpdateTool {
this.mcVersion.set(mcVersion)
this.mcVersion.set(minecraftVersion)
this.version.set(modVersion)
this.versionRecommended.set(property("versionRecommended") == "true")
this.updateCheckerFile.set(file(property("dynamictrees.version_info_repo.path") + File.separatorChar + property("updateCheckerPath")))
}

tasks.autoUpdate {
finalizedBy("publishMavenJavaPublicationToHarleyOConnorRepository", "curseforge")
doLast {
modrinth.changelog.set(changelogFile.readText())
}
finalizedBy("publishMavenJavaPublicationToHarleyOConnorRepository", "curseforge", "modrinth")
}

fun net.minecraftforge.gradle.common.util.RunConfig.applyDefaultConfiguration(runDirectory: String = "run") {
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
modName=DynamicTrees
modId=dynamictrees
modVersion=1.1.0-BETA3
modVersion=1.1.0-BETA4
group=com.ferreusveritas.dynamictrees

mcVersion=1.19.2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"ingredient": "minecraft:pumpkin_seeds",
"bottle": "dynamictrees:dendro_potion",
"output": "dynamictrees:dendro_potion{potion_index:2}",
"text": "This potion changes the tree species to its mega equivalent. (if available)"
"text": "This potion changes the tree species to its mega equivalent. Note that this only works on trees that have mega variants - spruce and jungle only by default."
},
{
"type": "relations",
Expand Down

0 comments on commit 8c8caee

Please sign in to comment.