Build Properties

The following properties can be used to refer to in the POM.

SCM information

The following revision information is extracted from the SCM system.

Property Description
build.scmRevision.id The latest revision number provided by the SCM.
build.scmRevision.date The date of the latest revision number provided by the SCM.
build.scmLocallyModified The status of the local files. If there a local modifications (that is the local sources differ from that stored in the remote repository), this value is true. If there are no differences, the value is false. If the status cannot be determined (e.g. because of a failure) the value is unknown. Only if this value is false the revision number can be trusted to refer to the right files.
build.scmLocallyModified.files The list of files that are modified locally. This property is only set, if build.scmLocallyModified has a value of true.
build.scmRevision.url Stores the URL to the SCM server.

Build Time Information

The following information refers to the build time.

Property Description
build.date The date the artifact has been built.
build.copyright.year The year information for the copyright notice. This is, if inception year and build year are the same, the inception year, otherwise it is the period starting with the inception year and ending with the build year. In short: ${project.inceptionYear}-${build.year}
build.date.pattern The pattern used to format the build.date. This format is also stored as a property to allow to parse the date. It may be easier to use build.timestamp.millis to format the build date, though.
build.timestamp.millis A convenience value that stores the build time in milliseconds.
build.timestamp.custom A convenience value that stores the build time in in a custom format.
build.timestamp.pattern A pattern to format the timestamp for the custom format. The default pattern is yyyyMMdd.HHmmss if none is explicitly specified. The formatted value is then stored in the build.timestamp.custom property.
build.year A convenience property that stores the year of the build.date.
build.duration.[name] On setting build points, the time (in milliseconds) within the build process is stored for further reference. Together with the time difference to the start of the build, the difference to the previous build point is also stored with a .diff suffix.

Build Execution Information

Information about the user and the system the artifact has been build by.

Property Description
build.user The name of the user/system that build the artifact. The plugin grabs the value of the property specified by user.name. If no such property value is present, the Java system property user.name is returned.
build.host.name The name of the host the build was executed on.
build.os.name The name of the operating system the build was executed on.
build.os.arch The name of the operating system's architecture the build was executed on.
build.os.version The name of the operating system's version the build was executed on.
build.java.runtime.name The name of the Java runtime that executes the build.
build.java.runtime.version The version of the Java runtime that executes the build.
build.java.vendor The name of the vendor of the Java product that executes the build.
build.java.vm The name of the Java virtual machine that executes the build.
build.java.compiler The name of the Java compiler used by the build.
build.java.vendor The name of the vendor of the Java product that executes the build.
build.maven.version The version of the Maven tool being executed to run the build.
build.maven.execution.cmdline The command line arguments passed to Maven.
build.maven.execution.goals The goals executed by Maven on the build.
build.maven.execution.isRoot Flag to indicate whether the project creating the artifact is the one the run has been started on (true) or if it is a sub module (false).
build.maven.execution.project In the case of a sub module (build.maven.execution.isRoot has a value of false) this provides the identifier of the project the build has been started.
build.maven.execution.opts The Maven options provided by the environment variable MAVEN_OPTS.
build.maven.execution.java.opts The Java options provided by the environment variable JAVA_OPTS.
build.maven.execution.profiles.active The list of profiles that had been active during the build.
build.maven.execution.profile.active.[profile-id] The source the profile has been provided in (e.g. settings.xml).
execution.property.[name] The properties set to Maven for the build. This includes environment variables as well as Maven specific properties.

The system information is provided by Java system properties os.name, os.arch and os.version as well as java.version and java.vendor. There is no additional information added by this plugin.

Build Artifact and Version Information

Artifact and version information for the build. This information is for convenience to construct version information to be used in the POM (e.g. to name the final file).

Property Description
build.groupId This is the group ID that is read from the POM.
build.artifactId This is the artifact ID that is read from the POM.
build.version This is the artifact version that is read from the POM.
build.version.major The major version number from the version specified in the POM.
build.version.minor The minor version number from the version specified in the POM.
build.version.micro The micro version number from the version specified in the POM.
build.version.buildNumber The build number from the version specified in the POM.
build.version.qualifier The qualifier from the version specified in the POM.
build.version.full The version may contain the date in a normalized form and the revision number. This information is controlled by the Mojo properties:
  • addBuildDateToFullVersion
  • addReleaseNumberToFullVersion

Project Information

Project information may be helpful for operations teams that look inside an artifact to find further information.

Property Description
project.page.home.url The URL to the project home page.
project.page.ops.url The URL to a resource that compiles resources relevant for the operations team. This property has to be explicitly set as a property.
project.category A value to categorize the artifact. This allows tools to render artifacts in multiple sections. This property has to be explicitly set as a property.
project.subcategory A value to further categorize the artifact. This allows tools to render artifacts in multiple sections. This property has to be explicitly set as a property.
project.tags A value to tag the artifact. This allows tools to organize multiple artifacts. This property has to be explicitly set as a property.