Hello Chon,

The message "failed to initialize mime mail" means that due to the absence
of mail.jar, ant will use its own implementation
of sending mail.

You wrote that ant does send an email, but the email does not look readable
:

>Build failed due to errors! View attached log file for details. (Also look
>for a separate email that contains details of the error.) begin 644
>build.html M/&AT;6P^#0H\:&5A9#X-"CQ-151!(&AT=' M97%U:78](D-O;G1E;G0M5'EP
>M92(@8V]N=&5N=#TB=&5X="]H=&UL.R!C:&%RPT*(" @(" @;6%R9VEN.B...

This "begin 644 build.html ... " kludge looks like the attachments that you
wanted to send.
For some reason, your email client is not able to detect that this is the
beginning of an attachment,
but displays it as text. Maybe you should end your text with a new line
before the beginning of the attachment

for instance, try writing your message like this :

 <message>Build failed due to errors!&#10;&#10;View
attached log file for details.  (Also look for a separate email that
contains details of the error.)
</message>

What you can also do is install mail.jar and activation.jar in the lib
directory of ant. Then ant will use Sun's email
implementation.


Antoine

----- Original Message ----- 
From: "Ivan Ivanov" <[EMAIL PROTECTED]>
To: "Ant Users List" <user@ant.apache.org>
Sent: Friday, December 16, 2005 11:44 PM
Subject: Re: Failed to initialise MIME mail


> Hello,
>
> --- "Chon, Ae H" <[EMAIL PROTECTED]> wrote:
> >             <mail mailhost= "${mail.host}"
> >
> >                   subject     = "BUILD FAILED:
> > ${product.name}
> > ${major.ver}.${minor.ver}.${patch}.${build.num}"
> >
> >                   charset = "utf-8"
> >
> >                   failonerror = "false"
> >
> >                   tolist      =
> > "${cm.list.address},${metrics.address}"
> >
> >                   messagemimetype = "text/html">
> >
> >                   <from address     =
> > "${from.address}" />
> >
> >                   <message>Build failed due to
> > errors!
>
> View
> > attached log file for details.  (Also look for a
> > separate email that
> > contains details of the error.)</message>
> >
> >                   <fileset dir = "${log.build.dir}">
> >
> >                         <include name =
> > "build.html"/>
> >
> >                   </fileset>
> >
> >             </mail>
> I checked the documentation of <mail> task in [1] and
> there is a similar example using a nested <fileset> as
> well. Its explanation says: "The task will attempt to
> use JavaMail and fall back to UU encoding or no
> encoding in that order depending on what support
> classes are available." So I suppose you need Java
> Mail.
>
> Regards
> Ivan
>
> [1]http://ant.apache.org/manual/CoreTasks/mail.html
>


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

Reply via email to