是否可以交出新的开发版本来发布:执行?

时间:2016-07-25 13:02:47

标签: maven maven-release-plugin

我想在发布中挂钩:执行步骤并执行一些自定义操作。这就像一个魅力 - 目前唯一不起作用的是将新的开发版本移交给发行版:执行调用。我的配置是这样的。我试着替换???使用project.version,但这不是我正在寻找的正确版本。

        <plugin>
           <groupId>org.apache.maven.plugins</groupId>
           <artifactId>maven-release-plugin</artifactId>
           <version>2.5.3</version>
           <configuration>
                    <!-- During release:perform, enable a special "mySpecialReleaseProfile" profile -->
              <releaseProfiles>mySpecialReleaseProfile</releaseProfiles>
              <!-- how to hand over the new development version to release:perform -->
              <arguments>-DtheNewDevelopmentVersion=${???} ${arguments}</arguments>
           </configuration>
        </plugin>

如果我使用-DdevelopmentVersion手动切换developmentVersion并使用以下配置,但是如果将developmentVersion作为-DdevelopmentVersion=xyz移交,由用户手动输入或自动增加,我希望此工作独立通过发布插件。

        <plugin>
           <groupId>org.apache.maven.plugins</groupId>
           <artifactId>maven-release-plugin</artifactId>
           <version>2.5.3</version>
           <configuration>
                    <!-- During release:perform, enable a special "mySpecialReleaseProfile" profile -->
              <releaseProfiles>mySpecialReleaseProfile</releaseProfiles>
              <!-- how to hand over the new development version to release:perform -->
              <arguments>-DtheNewDevelopmentVersion=${developmentVersion} ${arguments}</arguments>
           </configuration>
        </plugin>

0 个答案:

没有答案