I’ve had some experience with the Release plugin, but because of the number of times it commits to the repo, it cannot be used for Continuous Delivery.
Here’s an article that describes a workflow using the Versions plugin. It also leverages the fact that generally speaking, cloning a repo using a DVCS is quite fast, and much faster than it was using SVN. It also focused on reducing the number of steps. Basically, it does 1 clean/compile/test cycle, and doesn’t do any commits to the SCM. It merely tags the changeset in the repo.
To summarize. Clone the repo, use versions to set the version. clean/compile/test/deploy. Tag in SCM.
The changes to the pom don’t get committed to the SCM, but because of the tag, it’s easy to know which changeset was the build.
This will work fine with Git, but because of the way Mercurial does tagging, this will not work. A tag also requires a new changeset, which would trigger a build, which would…
Also note that the Versions plugin supports many other things relating to versions both of the project and of dependencies.