【发布时间】:2018-02-27 12:57:30
【问题描述】:
我需要发布一个较旧的分支来满足不同团队的依赖关系。设置是通过 Jenkins 使用 maven-release 插件进行的。 正如标题所暗示的,一切顺利,直到它到达复制到标记阶段,在该阶段它不是复制分支,而是复制主干并在尝试构建它时失败,因为主干设置为部署到不同的连接。
请帮助我几乎一整天都在绞尽脑汁。
当前詹金斯的目标:
-X -DdryRun=${DRY_RUN_MODE} -DbranchName=release_1.243 -Dapp.svn.repo=${APP_SVN_REPO} 干净发布:准备发布:执行
当前配置:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-deploy-plugin</artifactId>
<version>2.8.2</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>2.5.3</version>
<configuration>
<branchName>release_1.243</branchName>
<tagNameFormat>release_branch_@{project.version}</tagNameFormat>
</configuration>
</plugin>
<scm>
<connection>${project.svn.repo}/trunk</connection>
<!-- Because we have a single-module SVN repo with a FLAT multi-module
file structure, we need to point to this parent pom's folder in the developer
connection, not the root (trunk) repo. -->
<developerConnection>scm:svn:${project.svn.repo}/trunk/app-parent</developerConnection>
</scm>
【问题讨论】:
-
如果您在一个分支上工作,那么您应该将 scm 部分更改为相应的分支?
-
我在阅读您的评论之前就想通了,但您确实是正确的。谢谢
标签: java maven jenkins maven-release-plugin maven-scm