Class VersionCorrector
java.lang.Object
org.modelingvalue.gradle.mvgplugin.VersionCorrector
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCompute the vacant version and set it on all projects.static StringvacantVersion(String propVersion, List<String> tags) The vacant version is the patch successor of the highest version-like tag, or the gradle.properties version itself when that is higher than every tag (or when there are no version-like tags at all).
-
Field Details
-
DEV_VERSION
- See Also:
-
-
Constructor Details
-
VersionCorrector
-
-
Method Details
-
computeAndSetVersion
public void computeAndSetVersion()Compute the vacant version and set it on all projects. On CI the vacant version is the patch successor of the highest version-like git tag, or the gradle.properties version itself when that is higher than every tag (the way to deliberately start a new minor/major release line). Outside CI the version is always "dev": local artifacts are not for distribution and must not look like a release. This must be called at configuration time so that Gradle's configuration resolution (which freezes artifact file paths) sees the correct version. The gradle.properties file is intentionally not modified — the next vacant version is always derived from git tags. -
vacantVersion
The vacant version is the patch successor of the highest version-like tag, or the gradle.properties version itself when that is higher than every tag (or when there are no version-like tags at all).
-