b61cd60024
You can use Trigger Scripts in groovy to define before of after the build if the email must be send or not. See https://wiki.jenkins-ci.org/display/JENKINS/Email-ext+plugin#Email-extplugin-Triggers Change-Id: Id55df2c4796472c9283269e9e57815b8cf5ed52a
189 lines
8.7 KiB
XML
189 lines
8.7 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<project>
|
|
<publishers>
|
|
<hudson.plugins.emailext.ExtendedEmailPublisher>
|
|
<recipientList>foo@example.com, bar@example.com</recipientList>
|
|
<configuredTriggers>
|
|
<hudson.plugins.emailext.plugins.trigger.AlwaysTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.AlwaysTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.UnstableTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.UnstableTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.FirstFailureTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.FirstFailureTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.NotBuiltTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.NotBuiltTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.AbortedTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.AbortedTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.RegressionTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.RegressionTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.FailureTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.FailureTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.SecondFailureTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.SecondFailureTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.ImprovementTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.ImprovementTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.StillFailingTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.StillFailingTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.SuccessTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.SuccessTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.FixedTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.FixedTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.StillUnstableTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.StillUnstableTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.PreBuildTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
</hudson.plugins.emailext.plugins.trigger.PreBuildTrigger>
|
|
<hudson.plugins.emailext.plugins.trigger.ScriptTrigger>
|
|
<email>
|
|
<recipientList/>
|
|
<subject>$PROJECT_DEFAULT_SUBJECT</subject>
|
|
<body>$PROJECT_DEFAULT_CONTENT</body>
|
|
<sendToDevelopers>true</sendToDevelopers>
|
|
<sendToRequester>true</sendToRequester>
|
|
<includeCulprits>true</includeCulprits>
|
|
<sendToRecipientList>true</sendToRecipientList>
|
|
</email>
|
|
<triggerScript>build.result.toString().equals('SUCCESS')</triggerScript>
|
|
</hudson.plugins.emailext.plugins.trigger.ScriptTrigger>
|
|
</configuredTriggers>
|
|
<contentType>text/html</contentType>
|
|
<defaultSubject>Subject for Build ${BUILD_NUMBER}</defaultSubject>
|
|
<defaultContent>The build has finished</defaultContent>
|
|
<attachmentsPattern>*/foo*.log</attachmentsPattern>
|
|
<presendScript>cancel=true</presendScript>
|
|
<postsendScript>cancel=true</postsendScript>
|
|
<attachBuildLog>false</attachBuildLog>
|
|
<compressBuildLog>false</compressBuildLog>
|
|
<saveOutput>true</saveOutput>
|
|
<disabled>false</disabled>
|
|
<replyTo>foo@example.com</replyTo>
|
|
<matrixTriggerMode>ONLY_CONFIGURATIONS</matrixTriggerMode>
|
|
</hudson.plugins.emailext.ExtendedEmailPublisher>
|
|
</publishers>
|
|
</project>
|