Skip to content

Commit

Permalink
Fix automated upload
Browse files Browse the repository at this point in the history
  • Loading branch information
dhyces committed Nov 13, 2024
1 parent b9f65db commit 7ff127a
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 19 deletions.
18 changes: 9 additions & 9 deletions fabric/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -103,17 +103,17 @@ tasks.named("compileJava", JavaCompile) {
if (hasProperty("modrinth_write_version_pat")) {
modrinth {
token = findProperty("modrinth_write_version_pat") as String
projectId = properties["modrinth_project_id"] as String
versionName = "Fabric-${libs.versions.minecraft.release.get()}-${properties["mod_version"]}"
versionNumber = "${libs.versions.minecraft.release.get()}-${properties["mod_version"]}+fabric"
versionType = properties["publish_type"] as String
projectId = modrinth_project_id
versionName = "Fabric-${libs.versions.minecraft.release.get()}-${version}"
versionNumber = "${libs.versions.minecraft.release.get()}-${version}+fabric"
versionType = publish_type
uploadFile.set(tasks.remapJar)
gameVersions = List.of(libs.versions.publish.range.get().split(","))
loaders = List.of("fabric")
changelog = rootProject.file("changelog.md").text
additionalFiles = List.of(tasks.named("sourcesJar"), tasks.named("javadocJar"))
detectLoaders = false
debugMode = properties["publish_debug"].toString().toBoolean()
debugMode = publish_debug.toBoolean()
}
}

Expand All @@ -123,16 +123,16 @@ if (hasProperty("curseforge_publishing_token")) {

disableVersionDetection()
apiToken = findProperty("curseforge_publishing_token")
def projectId = properties["curseforge_project_id"]
def projectId = curseforge_project_id
def mainFile = upload(projectId, tasks.remapJar)
mainFile.displayName = "Fabric-${libs.versions.minecraft.release.get()}-${properties["mod_version"]}"
mainFile.releaseType = properties["publish_type"]
mainFile.displayName = "Fabric-${libs.versions.minecraft.release.get()}-${version}"
mainFile.releaseType = publish_type
mainFile.changelog = rootProject.file("changelog.md").text
mainFile.changelogType = "markdown"
mainFile.addModLoader("Fabric")
mainFile.addJavaVersion("Java ${java.toolchain.languageVersion.get()}")
mainFile.addGameVersion(libs.versions.minecraft.release.get())
debugMode = properties["publish_debug"].toString().toBoolean()
debugMode = publish_debug.toBoolean()

dependsOn(tasks.remapJar)
}
Expand Down
20 changes: 10 additions & 10 deletions neo/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -103,17 +103,17 @@ tasks.named("compileJava", JavaCompile) {
if (hasProperty("modrinth_write_version_pat")) {
modrinth {
token = findProperty("modrinth_write_version_pat") as String
projectId = properties["modrinth_project_id"] as String
versionName = "Fabric-${libs.versions.minecraft.release.get()}-${properties["mod_version"]}"
versionNumber = "${libs.versions.minecraft.release.get()}-${properties["mod_version"]}+neoforge"
versionType = properties["publish_type"] as String
projectId = modrinth_project_id
versionName = "Fabric-${libs.versions.minecraft.release.get()}-${version}"
versionNumber = "${libs.versions.minecraft.release.get()}-${version}+neoforge"
versionType = publish_type
uploadFile.set(tasks.jar)
gameVersions = List.of(libs.versions.publish.range.get().split(","))
loaders = List.of("neoforge")
changelog = rootProject.file("changelog.md").text
additionalFiles = List.of(tasks.named("sourcesJar"), tasks.named("javadocJar"))
detectLoaders = false
debugMode = properties["publish_debug"].toString().toBoolean()
debugMode = publish_debug.toBoolean()
}
}

Expand All @@ -123,17 +123,17 @@ if (hasProperty("curseforge_publishing_token")) {

disableVersionDetection()
apiToken = findProperty("curseforge_publishing_token")
def projectId = properties["curseforge_project_id"]
def projectId = curseforge_project_id
def mainFile = upload(projectId, tasks.jar)
mainFile.displayName = "NeoForge-${libs.versions.minecraft.release.get()}-${properties["mod_version"]}"
mainFile.releaseType = properties["publish_type"]
mainFile.displayName = "NeoForge-${libs.versions.minecraft.release.get()}-${version}"
mainFile.releaseType = publish_type
mainFile.changelog = rootProject.file("changelog.md").text
mainFile.changelogType = "markdown"
mainFile.addModLoader("NeoForge")
mainFile.addJavaVersion("Java ${java.toolchain.languageVersion.get()}")
mainFile.addGameVersion(libs.versions.minecraft.release.get())
debugMode = properties["publish_debug"].toString().toBoolean()
debugMode = publish_debug.toBoolean()

dependsOn(tasks.remapJar)
dependsOn(tasks.jar)
}
}

0 comments on commit 7ff127a

Please sign in to comment.