Class SemverExtension

java.lang.Object
com.xenoterracide.gradle.semver.SemverExtension
All Implemented Interfaces:
com.xenoterracide.gradle.git.Provides<org.semver4j.Semver>

public class SemverExtension extends Object implements com.xenoterracide.gradle.git.Provides<org.semver4j.Semver>
Extension for generating semantic versions from git metadata.
  • Semver
  • Method Summary

    Modifier and Type
    Method
    Description
    org.gradle.api.provider.Property<Boolean>
    Dirty checking will cause your configuration cache to need to be changed every single file change.
    org.gradle.api.provider.Provider<org.semver4j.Semver>
    Provider of Semver.
    org.gradle.api.provider.Property<String>
    Remote to use for head branch configuration.
    Returns a string representation of the object, which is retrieved from the provider's value.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Method Details

    • getProvider

      public org.gradle.api.provider.Provider<org.semver4j.Semver> getProvider()
      Provider of Semver. For a distance of 1 away from tag or your HEAD branch, but 40 commits on your deviated branch. 0.1.1-alpha.0.1+git.1.3aae11e. The longest example 0.1.1-alpha.0.1+branch.topic-foo.git.40.3aae11e.dirty
      Specified by:
      getProvider in interface com.xenoterracide.gradle.git.Provides<org.semver4j.Semver>
      Returns:
      semver provider
      Implementation Spec:
      <major>.<minor>.<patch>[-<preRelease.tag.headBranchDistance>][+branch.<branch>.]git.<distance>.<sha>[.dirty]]
      Implementation Note:
      The value will not be recalculated more than once per project per build. It is suggested to only use on the root project.
    • getCheckDirty

      public org.gradle.api.provider.Property<Boolean> getCheckDirty()
      Dirty checking will cause your configuration cache to need to be changed every single file change.
      Returns:
      dirty check configuration property
      Implementation Note:
      The plugin defaults to false
    • getRemote

      @Incubating public org.gradle.api.provider.Property<String> getRemote()
      Remote to use for head branch configuration.
      Returns:
      remote configuration property
      Implementation Note:
      The plugin defaults to "origin"
    • toString

      public String toString()
      Returns a string representation of the object, which is retrieved from the provider's value.
      Overrides:
      toString in class Object
      Returns:
      the string representation of the object provided by the provider