How can set properties for determine last commit revision and author in maven?

408 Views Asked by At

I want to get SCM url, last commit revision and last commit author so I can add them as metadata in my jar. I know I can get URL and revision but don't see a plugin which sets last commit author as a property.

  • last commit revision ${buildnumber} as buildnumber-maven-plugin executs
  • url: ${project.scm.url}
  • author: ?????

Please let me know if you know how to get the author. At present i suspect I'll execute svn info ${project.scm.url} -r ${buildnumber} and then parse the output.

Thanks

Peter

        <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>buildnumber-maven-plugin</artifactId>
        <version>1.2</version>
        <executions>
            <execution>
            <phase>validate</phase>
            <goals>
                <goal>create</goal>
            </goals>
            </execution>
        </executions>
        <configuration>
            <useLastCommittedRevision>true</useLastCommittedRevision>
            <doCheck>false</doCheck>
            <doUpdate>false</doUpdate>
        </configuration>
    </plugin> 
0

There are 0 best solutions below