I believe the versions-maven-plugin is the closest what you need,
but it will not "increment the hotfix part of the version by one" correctly if you are working on a release branch (for example 1.2.x) and a higher release has been made (for example 1.3.0).

More info here:

Op 21-03-12 20:03, Brett Porter schreef:
You can use this plugin for a wide range of version changes:

For automatic incrementing, you might look at the release plugin:

If neither of those do what you want, then it would probably be easier to make 
an enhancement to them rather than creating a new plugin. Rewriting the POM is 
not a tool we have generally available - both plugins have gone to some lengths 
to do that while preserving formatting, etc.

- Brett

On 22/03/2012, at 4:23 AM, Daniel Jones wrote:

Hi all,

I'm wondering if it would be possible/feasible to write a plugin that:

   1. Looks up the LATEST version of the current project
   2. Does some splitting on that version string to increment the minor
   revision by one
   3. Modifies the logical representation of the POM to the new version
   4. *Possibly* does some filtering that will then write the POM.xml file
   with the new version.

I'm guessing items 1 and 3 must exist in the codebase somewhere, so the
rest shouldn't be too hard. Has anyone attempted this before, and if not,
where would you recommend a developer completely new to Maven plug-ins
should look first?

Daniel Jones | Software Engineer, Platform Team

Mendeley Ltd | London, UK | www.mendeley.com<http://www.mendeley.com/>
Registered in England and Wales | Company Number 6419015
Brett Porter

With kind regards,
Geoffrey De Smet

To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org

Reply via email to