Using Maven Release Plugin with Source Integrity
Hello,
I tried to use the Maven Release Plugin together with source integrity.
I currently have 2 problems while using it:
1.
This plugin performs the following steps if executing the goal
mvn release:prepare
- Check that there are no uncommitted changes in the sources
- Check that there are no SNAPSHOT dependencies
- Change the version in the POMs from x-SNAPSHOT to a new version (you will be prompted for the versions to use)
- Transform the SCM information in the POM to include the final destination of the tag
- Run the project tests against the modified POMs to confirm everything is in working order
- Commit the modified POMs
- Tag the code in the SCM with a version name (this will be prompted for)
- Bump the version in the POMs to a new value y-SNAPSHOT (these values will also be prompted for)
- Commit the modified POMs
This works fine up until the point where the pom.xml should be bumped to the new version y-SNAPSHOT.
As far as I can see the file is checked-in/committed before the modification is done. This causes the file to be read-only, which by consequence prevents maven to modify the file and abort the build (blocking point for using the plugin, e.g. in continuous integration environments).
2.
It seems that the following characters are not allowed to be used for a checkpoint label:
$ , . : ; / \ @
Another real blocking-point, as it is usual to provide the version number of a project in the label. Maven has the version numbers in the following format: major.minor
From my analysis it is the SCM Provider implementation that should be adapted. I checked the sources here. Maybe the implementation could replace the dot in the version number with an underscore, hyphen or similar. It would be even better to be able to specify a system property (like for the Change-Package-Id) with e.g.:
-Dmaven.scm.integrity.versiondelimiter="-"
Has someone worked with the release plugin before and could possibly provide a solution?
The contact person mentioned in the SCM implementation is Cletus D'Souza (I did not write an email to him as the mentioned address uses
Thank you already for any help!
Attention: switching off read-only for check-in operations on the server for all projects is not an option.

