Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.3.2
-
None
-
None
Description
Setup your project with a <project><build><finalName> element setup like:
<finalName>${project.groupId}.${project.artifactId}-${project.version}</finalName>
Setup ${project.version} to a SNAPSHOT like:
<version>0.0.1-SNAPSHOT</version>
The key thing here is the use of ${project.version} in the <finalName> and ew start with a SNAPSHOT version trying to perform a release.
Now we run: mvn release:prepare-with-pom
It will bail out with error now and a message ... "Cannot reliably adjust the finalName of project:" and I believe this is due to the -SNAPSHOT being visible and the code that throw the exception is looking at the original, unedited version of the pom.xml.
I think after editing the pom.xml the in-memory model should be refreshed and all ${variable} be re-interpreted.