Add Hangar support for platform publishing - #1
Merged
Merged
Conversation
Still need to resolve 2 TODOs Once MPP has Hangar support, Hangar Publish Plugin won't be used anymore
There was a problem hiding this comment.
Pull request overview
This PR adds optional Hangar publishing support alongside the existing Mod Publish–based publishing (GitHub/Modrinth/CurseForge), including a shared release-channel mapping and Hangar-specific configuration hooks.
Changes:
- Add Hangar Publish Plugin integration to
setupPublishingPlatforms, including changelog, channel, and dependency wiring. - Introduce
ReleaseChannelto map a single release classification to both Mod Publish Plugin and Hangar. - Move
PluginPlatforminto theenumspackage and extendPublishingPlatformConfigwith a Hangar action/dependency DSL.
Reviewed changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/main/kotlin/xyz/srnyx/gradlegalaxy/utility/Setups.kt | Adds Hangar publishing configuration and refactors shared publishing metadata (release channel, primary file, changelog). |
| src/main/kotlin/xyz/srnyx/gradlegalaxy/utility/Scripts.kt | Adds Hangar plugin detection and a helper to fetch Hangar-supported platform versions. |
| src/main/kotlin/xyz/srnyx/gradlegalaxy/enums/ReleaseChannel.kt | Adds a shared release-channel enum mapping to Mod Publish Plugin and Hangar. |
| src/main/kotlin/xyz/srnyx/gradlegalaxy/enums/PluginPlatform.kt | Moves the PluginPlatform enum to enums and adds HANGAR. |
| src/main/kotlin/xyz/srnyx/gradlegalaxy/data/config/publishing/PublishingPlatformConfig.kt | Adds Hangar configuration action + dependency DSL to publishing config. |
| build.gradle.kts | Adds compileOnly dependency on the Hangar Publish Plugin Gradle plugin. |
Comments suppressed due to low confidence (1)
src/main/kotlin/xyz/srnyx/gradlegalaxy/enums/PluginPlatform.kt:1
- Changing PluginPlatform’s package from
xyz.srnyx.gradlegalaxy.data.platformstoxyz.srnyx.gradlegalaxy.enumsis a source-breaking change for Gradle Kotlin DSL users who import the old FQCN. Consider keeping backward compatibility via a deprecated typealias/forwarder in the old package (or avoid the package move until a major version).
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Still need to resolve 2 TODOs
Once Mod Publish Plugin has Hangar support, Hangar Publish Plugin won't be used anymore