Class ReleaseManifest
java.lang.Object
io.github.duckasteroid.gradle.versioning.releaseflow.ReleaseManifest
The
build/release-manifest.json file written by the tagReleaseCandidates /
promoteReleaseCandidates aggregator tasks (ReleaseFlowPlugin) - one entry per
project that actually got tagged on a given run, read back by the bundled GitHub Actions workflow
to turn into one gh release create per entry, instead of guessing a single tag via
git describe --tags --exact-match HEAD (which only ever worked when exactly one project
released per push).
A plain class with no Gradle dependency, like VersionResolver/ChangelogGenerator
- kept separate from the aggregator tasks themselves so the JSON shape is independently testable.
Uses Groovy's JsonOutput for serialization (available transitively via the Gradle API,
same as groovy.lang.Closure elsewhere in this project) rather than pulling in a separate
JSON library for this one small, flat shape.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidEquivalent toadd(String, String, String, List, String)with no supersededTags/artifactsDir.voidEquivalent toadd(String, String, String, List, String)with no artifactsDir.voidbooleanisEmpty()intsize()toJson()voidWrites this manifest as JSON to file, creating parent directories as needed.
-
Constructor Details
-
ReleaseManifest
public ReleaseManifest()
-
-
Method Details
-
add
public void add(String module, String tag, String changelog, List<String> supersededTags, String artifactsDir) - Parameters:
module- the Gradle project path, e.g. ":" for the root or ":api" for a subprojecttag- the full tag name that was just created, including its prefixchangelog- the generated changelog's path, relative to the repo rootsupersededTags- this cycle's previous release-candidate tags whose GitHub Release should be deleted now thattagsupersedes them (see thereleaseCandidates { }extension) - empty when pruning is disabled or nothing qualifies. The tags themselves are never deleted, only their GitHub Release.artifactsDir- this project's ownbuild/libsdirectory, relative to the repo root, for the workflow to glob jars out of and attach to the GitHub Release - see the note on why this is a directory to glob rather than literal file names inReleaseFlowPluginwhere it's computed.
-
add
Equivalent toadd(String, String, String, List, String)with no supersededTags/artifactsDir. -
add
Equivalent toadd(String, String, String, List, String)with no artifactsDir. -
isEmpty
public boolean isEmpty() -
size
public int size() -
toJson
-
writeTo
Writes this manifest as JSON to file, creating parent directories as needed.
-