使用#标签在触发建立在詹金斯/哈德森提交消息 [英] Trigger build in Jenkins/Hudson using hashtag in commit-message

查看:218
本文介绍了使用#标签在触发建立在詹金斯/哈德森提交消息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有可能引发哈德森/詹金斯只能建在某个字符串出现在提交消息?

Is it possible to trigger a Hudson/Jenkins build only when a certain string appears in a commit-message?

比如说,我要触发通过编写一个提交信息像推出我的应用程序的开发环境构建:

For instance, I want to trigger a build that rolls out my application to the dev environment by writing a commit message like:

MYPROJECT-123中的NPE MyClass.java #deploy:DEV

MYPROJECT-123 Fixed NPE in MyClass.java #deploy:DEV

总的想法是在这个精彩演讲描述在连续型部署但我无法找到如何做到这一点在哈德森的任何信息。

The general idea is described in this great talk on Continuos Deployment but I couldn't find any information on how to do this in Hudson.

我想preFER有在哈德森本身,而不是像提交钩或Web挂钩的外部系统这一行为。

I would prefer to have this behavior in Hudson itself and not in an external system like commit-hooks or web-hooks.

推荐答案

我不知道一个开箱即用的方式,你可以解析SCM消息作为触发的一部分。你有两个选择,可能达到你想要什么,虽然

I don't know of an out of the box way you can parse the SCM message as part of the trigger. You have a couple of options that might achieve what you want though


  1. 写自己的哈德森SCM插件

  2. 链条你们的工作一起到一个构建管道。第一份工作可以简单地查找该消息的changelog.xml以确定未来建设被触发与否。

如果您正在寻找在建设构建作业的管道,检查出的集结流水线插件。 http://www.centrumsystems.com.au/blog/?p=121

If you are looking at building a pipeline of build jobs, check out the build-pipeline-plugin. http://www.centrumsystems.com.au/blog/?p=121

任何人有一个更好的解决方案?

Anyone got a more elegant solution??

干杯,

杰夫

这篇关于使用#标签在触发建立在詹金斯/哈德森提交消息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆