Merge "Fix typo in ircbot's default matrix-notifier."

This commit is contained in:
Jenkins 2014-03-25 00:18:34 +00:00 committed by Gerrit Code Review
commit d281563b8b
5 changed files with 73 additions and 19 deletions

View File

@ -2754,25 +2754,9 @@ def ircbot(parser, xml_parent, data):
* **only-configurations** (default)
* **only-parent**
Example::
publishers:
- ircbot:
strategy: all
notify-start: false
notify-committers: false
notify-culprits: false
notify-upstream: false
notify-fixers: false
message-type: summary-scm
channels:
- name: '#jenkins-channel1'
password: secrete
notify-only: false
- name: '#jenkins-channel2'
notify-only: true
matrix-notifier: only-configurations
Example:
.. literalinclude:: /../../tests/publishers/fixtures/ircbot001.yaml
"""
top = XML.SubElement(xml_parent, 'hudson.plugins.ircbot.IrcPublisher')
message_dict = {'summary-scm': 'DefaultBuildToChatNotifier',
@ -2819,7 +2803,7 @@ def ircbot(parser, xml_parent, data):
matrix_dict = {'all': 'ALL',
'only-configurations': 'ONLY_CONFIGURATIONS',
'only-parent': 'ONLY_PARENT'}
matrix = data.get('matrix-notifier', 'only_configurations')
matrix = data.get('matrix-notifier', 'only-configurations')
if matrix not in matrix_dict:
raise JenkinsJobsException("matrix-notifier entered is not valid, "
"must be one of: %s" %

View File

@ -0,0 +1,27 @@
<?xml version="1.0" encoding="utf-8"?>
<project>
<publishers>
<hudson.plugins.ircbot.IrcPublisher>
<buildToChatNotifier class="hudson.plugins.im.build_notify.DefaultBuildToChatNotifier"/>
<strategy>ALL</strategy>
<targets>
<hudson.plugins.im.GroupChatIMMessageTarget>
<name>#jenkins-channel1</name>
<password>secrete</password>
<notificationOnly>false</notificationOnly>
</hudson.plugins.im.GroupChatIMMessageTarget>
<hudson.plugins.im.GroupChatIMMessageTarget>
<name>#jenkins-channel2</name>
<password/>
<notificationOnly>true</notificationOnly>
</hudson.plugins.im.GroupChatIMMessageTarget>
</targets>
<notifyOnBuildStart>false</notifyOnBuildStart>
<notifySuspects>false</notifySuspects>
<notifyCulprits>false</notifyCulprits>
<notifyFixers>false</notifyFixers>
<notifyUpstreamCommitters>false</notifyUpstreamCommitters>
<matrixMultiplier>ONLY_CONFIGURATIONS</matrixMultiplier>
</hudson.plugins.ircbot.IrcPublisher>
</publishers>
</project>

View File

@ -0,0 +1,16 @@
publishers:
- ircbot:
strategy: all
notify-start: false
notify-committers: false
notify-culprits: false
notify-upstream: false
notify-fixers: false
message-type: summary-scm
channels:
- name: '#jenkins-channel1'
password: secrete
notify-only: false
- name: '#jenkins-channel2'
notify-only: true
matrix-notifier: only-configurations

View File

@ -0,0 +1,22 @@
<?xml version="1.0" encoding="utf-8"?>
<project>
<publishers>
<hudson.plugins.ircbot.IrcPublisher>
<buildToChatNotifier class="hudson.plugins.im.build_notify.DefaultBuildToChatNotifier"/>
<strategy>ALL</strategy>
<targets>
<hudson.plugins.im.GroupChatIMMessageTarget>
<name>#jenkins-channel</name>
<password/>
<notificationOnly>true</notificationOnly>
</hudson.plugins.im.GroupChatIMMessageTarget>
</targets>
<notifyOnBuildStart>false</notifyOnBuildStart>
<notifySuspects>false</notifySuspects>
<notifyCulprits>false</notifyCulprits>
<notifyFixers>false</notifyFixers>
<notifyUpstreamCommitters>false</notifyUpstreamCommitters>
<matrixMultiplier>ONLY_CONFIGURATIONS</matrixMultiplier>
</hudson.plugins.ircbot.IrcPublisher>
</publishers>
</project>

View File

@ -0,0 +1,5 @@
publishers:
- ircbot:
channels:
- name: '#jenkins-channel'
notify-only: true