jgitver / jgitver-maven-plugin

maven core extension to automatically define versions using jgitver & git tags
https://jgitver.github.io/
Other
159 stars 42 forks source link

"-g" prefix option not available in maven plugin #126

Open otopetrik opened 5 years ago

otopetrik commented 5 years ago

Before submitting an issue I have first:

Found completed issue in the underlying library https://github.com/jgitver/jgitver/issues/24.

The functionality does not seem to be exposed in jgitver-maven-plugin.

Issue

version: 1.5.1

usage context:

Problem description:

Attempts:

n-peugnet commented 4 years ago

Hi ! If you still want this I made this PATTERN conf workaround to achive this result.

<configuration xmlns="http://jgitver.github.io/maven/configuration/1.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jgitver.github.io/maven/configuration/1.1.0 https://jgitver.github.io/maven/configuration/jgitver-configuration-v1_1_0.xsd">
  <strategy>PATTERN</strategy>
  <versionPattern>${v}${-~meta.COMMIT_DISTANCE}${-g~meta.GIT_SHA1_8}</versionPattern>
</configuration>