firstdarkdev / modpublisher

A dual publishing Gradle Plugin to publish mods to Modrinth, Curseforge and GitHub in one go
MIT License
17 stars 3 forks source link

Feature: Separate changelog/description for additional files. #5

Open iChun opened 5 months ago

iChun commented 5 months ago

I've seen from trial and from poking around in the code that the changelog for additional files are taken from the parent file. Would appreciate a way to set a different changelog to said additional files.

Thank you!

EDIT: I suppose this could also potentially be extended to file display names as well

hypherionmc commented 5 months ago

Hmm good point.

I'm thinking for this, maybe I can change the additional file method, to either take in just a file, or an Object, which would allow overriding the file display name and changelog.

If those properties are not defined, it will just fall back to the globally defined ones

hypherionmc commented 5 months ago

Implemented with 2.0.3

// Additional files to upload with a custom display name and changelog.
// Currently only supported on Curseforge
addAdditionalFile {
    // File, Task or String
    artifact jar
    displayName "Some Name"
    changelog "Hello Changelog"
}

Kotlin DSL

// Additional files to upload with a custom display name and changelog.
// Currently supports CurseForge only
addAdditionalFile {
    // File, Task or String
    artifact(tasks.jar)
    displayName("Test Name")
    changelog("Some Changelog")
}