Maven Release Plugin
  1. Maven Release Plugin
  2. MRELEASE-699

release:update-versions should support -DreleaseVersion too (not only -DdevelopmentVersion), so it also supports not suffixing the version with -SNAPSHOT

    Details

    • Type: Improvement Improvement
    • Status: Open Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: update-versions
    • Number of attachments :
      1

      Description

      The documentation
      http://maven.apache.org/plugins/maven-release-plugin/examples/update-versions.html
      states "The update-versions goal can use the same properties used by the prepare goal for specifying the versions to be used."
      That's not true, as releaseVersion is not supported:
      http://maven.apache.org/plugins/maven-release-plugin/prepare-mojo.html#releaseVersion

      This means, that if you do this:
      mvn --batch-mode release:update-versions -DdevelopmentVersion=1.2.0
      that the set version is not 1.2.0, but in fact 1.2.0-SNAPSHOT.

        Activity

        Hide
        Brett Porter added a comment -

        There's several things here:

        • I'm not quite sure of the motivation for update-versions in the first place - maybe we should recommend the versions plugin instead
        • regardless of the above, we need to document the differences, and fix the misleading statement (or apply this patch)
        • we still need to look at the one line change that appears to be correct but doesn't reference a specific fix
        Show
        Brett Porter added a comment - There's several things here: I'm not quite sure of the motivation for update-versions in the first place - maybe we should recommend the versions plugin instead regardless of the above, we need to document the differences, and fix the misleading statement (or apply this patch) we still need to look at the one line change that appears to be correct but doesn't reference a specific fix
        Hide
        Geoffrey De Smet added a comment -

        There is an alternative plugin to change the versions:
        http://maven.apache.org/plugins/maven-release-plugin/update-versions-mojo.html

        The release plugin goal "update-versions" should probably be deprecated in favor of that plugin.
        http://maven.apache.org/plugins/maven-release-plugin/update-versions-mojo.html

        Show
        Geoffrey De Smet added a comment - There is an alternative plugin to change the versions: http://maven.apache.org/plugins/maven-release-plugin/update-versions-mojo.html The release plugin goal "update-versions" should probably be deprecated in favor of that plugin. http://maven.apache.org/plugins/maven-release-plugin/update-versions-mojo.html
        Hide
        Tomislav Nakic-Alfirevic added a comment -

        @Geoffrey: Is this the one you wanted to link to?

        http://mojo.codehaus.org/versions-maven-plugin/

        mvn versions:set -DnewVersion=2.0.0

        Show
        Tomislav Nakic-Alfirevic added a comment - @Geoffrey: Is this the one you wanted to link to? http://mojo.codehaus.org/versions-maven-plugin/ mvn versions:set -DnewVersion=2.0.0
        Hide
        Geoffrey De Smet added a comment -

        @Tomislav: yes

        Show
        Geoffrey De Smet added a comment - @Tomislav: yes
        Hide
        Torsten Liermann added a comment -

        This is also true for the branch goal. Specifying a -DreleaseVersion=1.0 the release plugin generate as release version 1.0-SNAPSHOT. But when the plugin ask for the branch version, the created branch pom will be correct.

        Show
        Torsten Liermann added a comment - This is also true for the branch goal. Specifying a -DreleaseVersion=1.0 the release plugin generate as release version 1.0-SNAPSHOT. But when the plugin ask for the branch version, the created branch pom will be correct.

          People

          • Assignee:
            Unassigned
            Reporter:
            Geoffrey De Smet
          • Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated: