简体   繁体   English

Jenkins git Refspec构建master和任何v *分支

[英]Jenkins git Refspec to build master and any v* branches

Our developers use temporary branches but I only want to build any commits to master and any v* branches (eg v1.0 , v1.0 , v1.1 , etc.) 我们的开发人员使用临时分支,但我只想构建对master和任何v*分支的任何提交(例如v1.0v1.0v1.1等)

I am trying the following in the Refspec field: 我正在Refspec字段中尝试以下操作:

+refs/heads/master:refs/remotes/origin/master 
+refs/heads/v*:refs/remotes/origin/v*

but jenkins kicks out the following error: 但是詹金斯踢出了以下错误:

stderr: fatal: Invalid refspec '+refs/heads/v*:refs/remotes/origin/v*'

Looks like my issue was my git client was 1.9.1. 看来我的问题是我的git客户端是1.9.1。 I am going to change my docker base image to ubuntu 16 which should have a newer git client. 我将将docker基本映像更改为ubuntu 16,该映像应具有较新的git客户端。

verified that this resolved the issue. 验证此问题已解决。 I upgraded to ubuntu 16 which had a git cli of 2.7.4 and now the refspec is working as intended. 我升级到git cli为2.7.4的ubuntu 16,现在refspec可以按预期工作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 同步GIT:refspec主站与任何主机都不匹配 - Syncing GIT : refspec master does not match any cvs2git隐藏cvs到git并推送多个分支得到:错误:src refspec master与任何不匹配 - cvs2git covert cvs to git and push multiple branches gets: error: src refspec master does not match any git错误-“错误:src refspec master不匹配。” - git error - “error: src refspec master does not match any.” Aptana Studio GIT:src refspec master与任何不匹配 - Aptana Studio GIT: src refspec master does not match any git->错误:src refspec master与任何不匹配 - Git --> error: src refspec master does not match any 合并git分支以使用Jenkins掌握 - Merging git branches to master using Jenkins 当我执行“git push origin master”时,Github 出错(错误:src refspec master 不匹配) - Error in Github when I do “git push origin master” (error: src refspec master does not match any) Jenkins / Git:从任何提交构建最新的分支+手动构建 - Jenkins/Git: Build latest from branches + manual build from any commit git push到第二个git repo失败:错误:src refspec master与任何不匹配 - git push to second git repo fail: error: src refspec master does not match any Git:错误:即使在运行 git commit -m 之后,src refspec master 也不匹配 - Git: error: src refspec master does not match any even after running git commit -m
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM