Add EngineConfiguration#versioningString

This commit is contained in:
JeremyStar™ 2024-06-29 22:15:35 +02:00
parent 87a7603c2e
commit ae3075770d
Signed by: JeremyStarTM
GPG key ID: E366BAEF67E4704D
2 changed files with 16 additions and 0 deletions

View file

@ -27,6 +27,8 @@ import java.lang.annotation.*;
/**
* Annotation for registering events on methods.
*
* @since 1-alpha0
*/
@SuppressWarnings("unused")
@Retention(RetentionPolicy.RUNTIME)

View file

@ -112,6 +112,19 @@ public final class EngineInformation {
*/
private String versioningFork;
/**
* Provides the engine's full version string.
*
* @since 1-alpha1
*
* -- GETTER --
* Provides the engine's full version string.
*
* @return engine version string
* @since 1-alpha1
*/
private String versioningString;
/**
* Provides the {@code dirty} value (i.e. if the source tree has been modified).
@ -418,6 +431,7 @@ public final class EngineInformation {
versioningType = VersionType.valueOf(gradleParser.getString("versioningType").toUpperCase());
versioningTyperelease = gradleParser.getInteger("versioningTyperelease", true);
versioningFork = gradleParser.getString("versioningFork");
versioningString = "v" + versioningVersion + "-" + (versioningType == VersionType.RELEASE_CANDIDATE ? "releasecandidate" : versioningType.name()) + versioningTyperelease + versioningFork;
dependencyLombok = gradleParser.getString("dependencyLombok");
dependencyJetbrainsAnnotations = gradleParser.getString("dependencyJetbrainsAnnotations");