Skip to content

Commit a3c1efd

Browse files
committed
Hopefully update modrinth publishing
1 parent 8409eac commit a3c1efd

File tree

1 file changed

+15
-16
lines changed

1 file changed

+15
-16
lines changed

build.gradle

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ plugins {
33
id 'maven-publish'
44
id 'com.diffplug.spotless' version '5.14.0'
55
id 'com.matthewprenger.cursegradle' version '1.4.0'
6-
id "com.modrinth.minotaur" version "1.2.1"
6+
id "com.modrinth.minotaur" version "2.+"
77
}
88

99
sourceCompatibility = JavaVersion.VERSION_17
@@ -296,20 +296,19 @@ if (System.getenv("CURSEFORGE_API_KEY") && !version.endsWith("-SNAPSHOT")) {
296296
}
297297
}
298298

299-
import com.modrinth.minotaur.TaskModrinthUpload
300-
301-
task publishModrinth (type: TaskModrinthUpload){
302-
onlyIf {
303-
System.getenv("MODRINTH_API_KEY") && !version.endsWith("-SNAPSHOT")
299+
if (System.getenv("MODRINTH_API_KEY") && !version.endsWith("-SNAPSHOT")) {
300+
modrinth {
301+
token = System.getenv("MODRINTH_API_KEY")
302+
projectId = project.modrinth_project
303+
versionNumber = version
304+
versionName = "Modern Dynamics v${version}"
305+
delegate.changelog = changelog
306+
versionType = releaseChannel.toUpperCase()
307+
uploadFile = remapJar.archiveFile
308+
gameVersions = ["1.19.1", "1.19.2"]
309+
loaders = ["fabric"]
310+
dependencies {
311+
required.project "fabric-api"
312+
}
304313
}
305-
token = System.getenv("MODRINTH_API_KEY")
306-
projectId = project.modrinth_project
307-
versionNumber = version
308-
versionName = "Modern Dynamics v${version}"
309-
delegate.changelog = changelog
310-
versionType = releaseChannel.toUpperCase()
311-
uploadFile = remapJar.archiveFile
312-
addGameVersion "1.19.1"
313-
addGameVersion "1.19.2"
314-
addLoader "fabric"
315314
}

0 commit comments

Comments
 (0)