File tree Expand file tree Collapse file tree 3 files changed +43
-0
lines changed Expand file tree Collapse file tree 3 files changed +43
-0
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ plugins {
2
2
id " fabric-loom" version " 1.6+"
3
3
id " com.github.johnrengelman.shadow" version " 8.1+"
4
4
id " maven-publish"
5
+ id " me.modmuss50.mod-publish-plugin" version " 0.5.2"
5
6
}
6
7
7
8
version = project. mod_version
@@ -43,6 +44,45 @@ processResources {
43
44
}
44
45
}
45
46
47
+ publishMods {
48
+ displayName = " ramel ${ project.version} "
49
+ file = remapJar. archiveFile
50
+ changelog = rootProject. file(" CHANGELOG.md" ). getText()
51
+ type = STABLE
52
+
53
+ modLoaders. add(" quilt" )
54
+ modLoaders. add(" fabric" )
55
+
56
+ dryRun = ! providers. environmentVariable(" MODRINTH_TOKEN" ). isPresent()
57
+ || ! providers. environmentVariable(" CURSEFORGE_TOKEN" ). isPresent()
58
+ || property(" pub.should_publish" ) == " false"
59
+ dryRun = false
60
+
61
+ var mcVersions = [project. minecraft_version]
62
+ mcVersions. addAll(property(" pub.additional_versions" ). toString(). split(" " ). findAll { ! it. empty })
63
+
64
+ modrinth {
65
+ projectId = " 4Uw92C2y"
66
+ accessToken = providers. environmentVariable(" MODRINTH_TOKEN" )
67
+ mcVersions. forEach(minecraftVersions ::add)
68
+
69
+ requires(" fabric-api" )
70
+ optional(" modmenu" )
71
+ }
72
+
73
+ curseforge {
74
+ accessToken = providers. environmentVariable(" CURSEFORGE_TOKEN" )
75
+ projectId = " 877074"
76
+ mcVersions. forEach(minecraftVersions ::add)
77
+
78
+ clientRequired = true
79
+ serverRequired = false
80
+
81
+ requires(" fabric-api" )
82
+ optional(" modmenu" )
83
+ }
84
+ }
85
+
46
86
def targetJavaVersion = 17
47
87
tasks. withType(JavaCompile ). configureEach {
48
88
it. options. encoding = " UTF-8"
Original file line number Diff line number Diff line change @@ -11,3 +11,6 @@ kaleido_config_version=0.3.1+1.3.2
11
11
mod_version = 1.0.5+mc1.21.1
12
12
maven_group = io.ix0rai
13
13
archives_base_name = ramel
14
+
15
+ pub.should_publish = true
16
+ pub.additional_versions = 1.21
You can’t perform that action at this time.
0 commit comments