ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Praveen" <bprav...@mahindrabt.com>
Subject RE: Ant 1.6.2 email with attachmennt
Date Fri, 27 Aug 2004 08:53:05 GMT

Peter,
	I suggest u to use "mimemail" task instead of "mail" task.  U can find out
the attributes and the nesting of other elements/ data types in the text
given below. I hope u'll get the required result. U can find the same text
in the ANT- TheDefinitiveguide.pdf file which is available at
http://max.hosting.ru Check that out.


mimemail :- org.apache.tools.ant.taskdefs.optional.net.MimeMail

Sends SMTP mail with MIME attachments. This task requires the JavaMail API
and the
JavaBeans Activation Framework. This differs from the core mail task in that
it supports
attachments.

Attributes
bcclist (1.4, String, *)
A comma-delimited list of BCC recipients.
cclist (1.4, String, *)
A comma-delimited list of CC recipients.
failonerror (1.4, boolean, N)
If true, abort the build on failure. Defaults to true.
from (1.4, String, Y)
The sender's email address.
mailhost (1.4, String, N)
The mail server name. Defaults to localhost.
message (1.4, String, *)
The message body.
messagefile (1.4, File, *)
A file containing the message body.
messagemimetype (1.4, String, N)
MIME type of attached message when using message or messagefile attributes.
Defaults to text/plain.
subject (1.4, String, N)
The email subject line.
Ant: The Definitive Guide
tolist (1.4, String, *)
A comma-delimited list of TO recipients.
Specify exactly one of message or messageFile, or specify a nested
<fileset>. At least one
of tolist, cclist, or bcclist must be specified.
Content
0..n nested <fileset> elements (1.4)
fileset elements specifying files to attach.



-----Original Message-----
From: Inman, Peter [mailto:peterinman@mcpplc.com]
Sent: Friday, August 27, 2004 1:34 PM
To: 'user@ant.apache.org'
Subject: Ant 1.6.2 email with attachmennt

I'm having trouble sending an attachment with an email. I had this problem
with ant1.5.3, so it's not 1.6 related.

I'd be grateful if someone could point me to where I'm going wrong. I get
the mail message, but no attachments.

     <target name="sendMailTest" depends="init">
     <mail mailhost="128.1.1.101" subject="Destin8 Build - BuildLog"
encoding="plain" tolist="peterinman@mcpplc.com">
        <from address="Destin8Build"/>
        <message>Build Log File</message>
        <fileset dir=".">
          <include name="builddestin8.properties"/>
        </fileset>
     </mail>
   </target>

Pete


*********************************************************
Disclaimer:          

This message (including any attachments) contains 
confidential information intended for a specific 
individual and purpose, and is protected by law. 
If you are not the intended recipient, you should 
delete this message and are hereby notified that 
any disclosure, copying, or distribution of this
message, or the taking of any action based on it, 
is strictly prohibited.

*********************************************************
Visit us at http://www.mahindrabt.com


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message