【发布时间】:2015-10-20 20:33:12
【问题描述】:
我正在尝试基于条件正则表达式匹配运行 Jenkins 构建步骤,但我不知道为什么它不匹配。
我正在使用这个正则表达式:.*iOS. 反对构建参数 pmt_content。
这是 pmt_content 值:
<body><pre>^1234567890^abc123def132afd1213afas^iOS^Test User^test@abc.com^iPad 3^</pre><img src='https://cirrus.app47.com/notifications/5626a0bc9ac25b6ea7003f2f/img' alt=''/></body>
这是控制台日志,告诉我它不匹配。
[PollMailboxTrigger] An email matching the filter criteria was found. (log)
Building in workspace /Users/jenkins/.jenkins/jobs/New Device Listener/workspace
Run condition [Regular expression match] enabling prebuild for step [Execute shell]
Regular expression run condition: Expression=[.*iOS.*], Label=[
<body><pre>^1234567890^abc123def132afd1213afas^iOS^Test User^test@abc.com^iPad 3^</pre><img src='https://cirrus.app47.com/notifications/5626a0bc9ac25b6ea7003f2f/img' alt=''/></body>]
Run condition [Regular expression match] preventing perform for step [Execute shell]
Finished: SUCCESS
显然 pmt_content 包含“iOS”。
我在 www.regexplanet.com 上测试了相同的值。
我做错了什么?
【问题讨论】: