-
Notifications
You must be signed in to change notification settings - Fork 0
Platform Notes
- Uses
gameVersion(defaults toproject.hytale_version) - Ensure your
hytale_versionmatches a valid Modtale-supported version - Accepts dynamic selectors like
0.+— see Game Version for details - Use
modtale.patchline("release"or"pre-release") to scope dynamic resolution to a specific Hytale Maven repo
- Uses numeric
gameVersionIds - Defaults to
[14284](Hytale Early Access)
-
gameVersionsandloadersmust be arrays. -
gameVersionsmust contain exact Hytale game version names, for example0.5.0-pre.9.1. - The old
Early Accessversion category is no longer valid. - If
modifold.gameVersionsis omitted, the plugin falls back tohytalePublisher.gameVersion/project.hytale_version. - Multiple supported game versions can be uploaded at once.
- These are automatically JSON-encoded by the plugin
- Supports four dependency types via the DSL:
-
required(slug, versionId?)— the dependency is required for this build to work -
optional(slug, versionId?)— the dependency is optional -
incompatible(slug, versionId?)— this build is incompatible with the dependency -
embedded(slug, versionId?)— the dependency is bundled inside this build
-
- The
versionIdargument is optional; omit it to allow any version of the dependency
- Authentication uses Thunderstore service-account API tokens, not your user account. Generate one at:
thunderstore.io -> Settings -> Teams -> [your team] -> Service Accounts. - The package version must be SemVer (
MAJOR.MINOR.PATCH). If your project version includes a qualifier like-beta, the plugin strips it for the Thunderstore manifest. Once a version is uploaded it cannot be reused, bump your version for every release. - The plugin auto-generates
manifest.jsoninside the zip from your DSL. You don't need to maintain a manifest in your repo, but you DO need:-
icon.png(256x256 PNG) at the project root -
README.mdat the project root ...both are required by Thunderstore.
-
-
hytalePublisher.changelogFileis bundled asCHANGELOG.mdinside the package zip. If the file is missing, HytalePublisher creates it automatically. Existing changelog files are matched case-insensitively. - The Hytale community slug is
hytale. Browse available category slugs at: https://thunderstore.io/api/experimental/community/hytale/category/ - Content folder conventions match the Hytale Modding Thunderstore guides:
- Plugins (.jar) ->
mods/ - Early plugins (.jar) ->
earlyplugins/ - Asset packs (.zip) ->
mods/ - Worlds ->
worlds/ - Universes ->
universes/ - Saves ->
saves/
- Plugins (.jar) ->
- Once a package is uploaded, its
nameandteamare immutable. Triple check both before your first publish.
- Creates a GitHub Release via the REST API. The release's
tag_nameis created automatically as part of creating the release — there's no separate tag/push step, and no way to publish a release without a tag (that's how GitHub Releases work). -
github.repository("owner/repo") is optional. If omitted, it's auto-detected from theorigingit remote (both SSH and HTTPS remote URLs are supported). - The tag defaults to
tagPrefix + projectVersion, e.g.v1.0.0. Override withgithub.tagPrefix. -
github.targetCommitishdefaults to the currentHEADcommit SHA (resolved viagit rev-parse HEAD). Set it explicitly if publishing from a detached or shallow checkout wheregitcommands might not resolve as expected — shallow checkouts (fetch-depth: 1) can still resolveHEAD, but full history (fetch-depth: 0) is recommended for reliability. - Attaches the built jar, sources jar, and javadoc jar as release assets. Sources/javadoc are skipped with a warning (not a failure) if no
sourcesJar/javadocJartask is found — this matches the task names produced by Gradle'sjava.withSourcesJar()/withJavadocJar(). - Additional files can be attached with
asset("path/to/file"), resolved relative to the project directory unless given as an absolute path. -
releaseTypevalues other than"release"(e.g."beta","alpha") automatically mark the GitHub release as a prerelease. Disable this withautoPrerelease = false, or force it withprerelease = true. - Upload failures (4xx/5xx responses) fail the build immediately with the HTTP status code and full error body from GitHub.
-
Workflow trigger caution: if your CI workflow triggers on
release: types: [published]and you also enablegithub.enabled = true, publishing will try to create another release for a tag that already exists, which fails. Either trigger the workflow onpush: tags/workflow_dispatchinstead, or keepgithub.enabled = falsein workflows meant to run in response to a release you already created manually.
-
Uses Gradle's built-in
maven-publishplugin under the hood rather than a custom uploader —maven.enabled = trueapplies that plugin automatically, so you don't need to add it yourself. -
maven.urlis required. Ifmaven.snapshotUrlis also set and the resolvedversionends with-SNAPSHOT, that URL is used instead — the common release/snapshot repository split. -
groupId,artifactId, andversiondefault toproject.group,project.name, andhytalePublisher.versionrespectively. Override any of them individually if your published coordinates should differ from the project's own. -
Attaches the built jar by default.
includeSourcesJar/includeJavadocJarattachsourcesJar/javadocJartask outputs if present, and are skipped with a warning (not a failure) otherwise — this matches Gradle'sjava.withSourcesJar()/withJavadocJar()task names, same as the GitHub target. -
Additional files can be attached with
artifact("path/to/file"), resolved relative to the project directory unless given as an absolute path. -
The generated POM only includes what you set via
pomName/pomDescription/pomUrl— it does not pull in your project's dependencies, since Hytale-mapped dependencies generally aren't resolvable through a normal Maven<dependencies>block anyway. For anything else (licenses, developers, SCM info), use thepom { }escape hatch, which is handed Gradle'sMavenPomdirectly. -
Credentials are optional — if
mavenUsername/mavenPassword(or their env equivalents) aren't set, HytalePublisher logs an info message and attempts to publish without credentials, which works fine for repositories that permit unauthenticated writes. -
allowInsecureProtocolmust be set totrueif your repository URL is plainhttp://rather thanhttps://. It defaults tofalse. -
Under the hood,
publishToMavenis an alias for Gradle's auto-generatedpublish<PublicationName>PublicationTo<RepositoryName>Repositorytask, so it composes normally with other Gradlemaven-publishtooling if you need it. -
Shadow plugin caution: if you use
com.gradleup.shadow(orcom.github.johnrengelman.shadow) and setshadowJar.archiveClassifier.set('')to make the shaded jar your "final" build output,shadowJarand the plainjartask now write to the same file. Gradle's task validation will fail with something likeuses this output of task ':jar'/':shadowJar' without declaring an explicit or implicit dependency, because it can't tell which task actually produced the file being published. Fix it with two changes:- Set
maven.jarTaskName = "shadowJar"so the plugin publishes (and depends on) the shaded jar rather than the plain one. - Give the plain
jartask a distinct classifier so it no longer collides, e.g.jar { archiveClassifier.set('slim') }.
This doesn't just silence the validation error — without it, there's a real risk of publishing the unshaded jar if task ordering ever shifts.
- Set