Send Email Based On Conditional

416 views
Skip to first unread message

Mark Bretl

unread,
Mar 5, 2013, 5:42:02 PM3/5/13
to jenkins...@googlegroups.com

Hello Jenkins Users,

 

I am looking for a way to send an email, using Email-Ext plugin, based on the result of a custom conditional. Reading the Email-Ext page, it can be triggered with build result statuses, but that is a static list as far I can tell. The other way I thought of to send an email is using the run condition plugin since is able to be used with build-steps and publishers, through the flexible-publish plugin, but it does not work with the notifier plugins such as Email-Ext...so that is a dead end.

 

One 'ugly' workaround I have thought of would be to set the build result, based on a Boolean conditional, to an unused status such as 'Not Built' hoping it won't collide with it in the future. I would then use that to send an email with the Email-Ext plugin and trigger it on 'Not Built'.

 

Any thoughts on possible solutions?

Mark Bretl
GemFire & SQLFire Build Engineer
Member of Technical Staff
VMware Inc.
503-533-3869

Slide

unread,
Mar 5, 2013, 5:50:13 PM3/5/13
to jenkins...@googlegroups.com
There are two things you could do:

1) use a pre-send script to cancel the sending of the email if your condition is not met
2) wait for the next release in which I am adding a PreBuildScriptTrigger and an ScriptTrigger, which will allow you to determine your own method for when an email should be sent.

slide


--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--
Website: http://earl-of-code.com

Eduardo Dias

unread,
Mar 6, 2013, 8:18:42 AM3/6/13
to jenkins...@googlegroups.com
Great news Slide, I am trying to to something like Mark and this features at plugin will help me to configure my email notifications.
Do you have idea when it will be available?

Regards,
Eduardo


2013/3/5 Slide <slide...@gmail.com>



--

Atenciosamente,

Eduardo

Alex Earl

unread,
Mar 6, 2013, 8:25:27 AM3/6/13
to Eduardo Dias, jenkins...@googlegroups.com
I'm trying to release more often, so I hope to have the script triggers in and do a release in two weeks. Hopefully that is not too long to wait. I could possibly give you an rc build earlier if you wanted.

Sent from my Windows Phone

From: Eduardo Dias
Sent: 3/6/2013 6:18
To: jenkins...@googlegroups.com
Subject: Re: Send Email Based On Conditional

Reply all
Reply to author
Forward
0 new messages