Addded the ability to specify the semver property key.

This commit is contained in:
Erik C. Thauvin 2019-04-11 10:14:36 -07:00
parent 1b12eba58b
commit 963966eb1c
4 changed files with 23 additions and 4 deletions

View file

@ -70,6 +70,7 @@ open class SemverConfig {
override fun toString(): String {
return "SemverConfig(" +
"properties='$properties', " +
"semver='$semverKey', " +
"majorKey='$majorKey', " +
"minorKey='$minorKey', " +
"patchKey='$patchKey', " +
@ -79,6 +80,6 @@ open class SemverConfig {
"buildMetaPrefixKey='$buildMetaPrefixKey', " +
"separator='$separatorKey', " +
"keysPrefix='$keysPrefix')" +
")"
')'
}
}

View file

@ -93,6 +93,8 @@ object Utils {
put(config.patchKey, version.patch)
put(config.preReleaseKey, version.preRelease)
put(config.buildMetaKey, version.buildMeta)
put(config.semverKey, version.semver)
put(config.buildMetaPrefixKey, version.buildMetaPrefix,
version.buildMetaPrefix != Version.DEFAULT_BUILDMETA_PREFIX ||
containsKey(config.buildMetaPrefixKey))

View file

@ -78,7 +78,7 @@ class Version {
"preReleasePrefix='$preReleasePrefix', " +
"buildMeta='$buildMeta', " +
"buildMetaPrefix='$buildMetaPrefix', " +
"separator='$separator'" +
")"
"separator='$separator', " +
')'
}
}