maven-2 - Maven 发布 :perform without deploy and calling an external shell script

标签 maven-2 maven-release-plugin

我正在使用 Maven 发布插件。问题很简单:我不想在发布时进行部署:执行。我实际上想执行一个 shell 脚本来为我进行部署。所以我有两件事要完成:

  • 不知何故禁用了发布中的默认“部署”目标:执行
  • 不知何故 make release:perform 调用 exec:exec 插件来执行一个 shell 脚本

  • 这是我的pom:
    <plugin>
        <artifactId>maven-release-plugin</artifactId>
        <version>2.0</version>
        <configuration>
            <tagBase>svn://saoj-la.dyndns.org/webapp-test/tags</tagBase>
            <connectionUrl>scm:svn:svn://saoj-la.dyndns.org/webapp-test/trunk</connectionUrl>
        </configuration>
    </plugin>
    
    <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>exec-maven-plugin</artifactId>
        <executions>
            <execution>
                <goals>
                    <goal>exec</goal>
                </goals>
            </execution>
        </executions>
        <configuration>
            <executable>/bin/sh</executable>
            <arguments>
                <argument>run.sh</argument>
            </arguments>
        </configuration>
    </plugin>
    

    最佳答案

    有点晚了,但供引用:

    对于您的第 1 步,您可以使用“跳过”选项禁用 Maven 部署步骤。点击here以供引用。

    在命令行上,您可以调用类似:

    mvn release:perform -Darguments="-Dmaven.deploy.skip=true"
    

    关于maven-2 - Maven 发布 :perform without deploy and calling an external shell script,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3445075/

    相关文章:

    maven-release-plugin - maven 发布插件和命令行参数

    maven-2 - 使用 Maven 创建一个包含用户可访问的配置文件的简单应用程序

    java - 添加附加路径到 exec-maven-plugin

    java - 将参数传递给 Maven 发布版本

    java - 从命令行覆盖 pom pluginManagement 中定义的 Maven 插件配置

    Maven 父项目上的 Maven 部署失败

    java - Eclipse 中的 Maven 2 项目错误图标

    java - 是否有任何 XML lint maven 插件?

    java - 使用 maven2 插件自动生成串行版本 uid

    maven-2 - Maven Release Plugin部署sources.jar和javadoc.jar