Interesting, I didn't know you could do that.  However I want to add some
custom messages and maybe some extra logic - not just mailing the logs.  

I think Cruise Control is a good solution to manage the email notifications. 
I am going to be using it anyways for automated builds.


Knuplesch, Juergen wrote:
> 
> You can do this by configuring the maillogger in your startscript:
> 
> ant build_ant.xml -logger org.apache.tools.ant.listener.MailLogger 
> 
> Then you have to set the following properties
> MailLogger.mailhost=
> MailLogger.from=
> MailLogger.failure.subject=failed
> MailLogger.success.subject=successfull
> [EMAIL PROTECTED]
> [EMAIL PROTECTED]
> 
> Then you will send the output of Ant to the specifies addresses.
> 
> Another strategy (big solution) is using CruiseControl
> 
> 
> 
> 
> 
> 
> -- 
> Jürgen Knuplesch
> -----Ursprüngliche Nachricht-----
> Von: p2008 [mailto:[EMAIL PROTECTED] 
> Gesendet: Mittwoch, 23. Juli 2008 00:35
> An: user@ant.apache.org
> Betreff: How to run an ant target on success/failed build
> 
> 
> I need to be able to trigger running a specific ant target when the build
> succeeds, and another one when it fails.  This will be used to send out an
> email indicating the status of the build.
> 
> I have done this in the past in nant (.NET) which has a built in property
> called nant.onsuccess and one called nant.onfailure.  
> 
> Is there something similar in ant, or any does anybody know how to do
> this?
> 
> Thanks!
> --
> View this message in context:
> http://www.nabble.com/How-to-run-an-ant-target-on-success-failed-build-tp18600235p18600235.html
> Sent from the Ant - Users mailing list archive at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/How-to-run-an-ant-target-on-success-failed-build-tp18600235p18615588.html
Sent from the Ant - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to