ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kyle Adams" <kad...@gfs.com>
Subject Re: How do I get a newline in Mail task message
Date Fri, 04 Jan 2002 18:08:00 GMT
Where is your buildMessage stored at?  I believe that if it's stored in a properties file,
you can use '\n' to add a newline to the end of that property.

I don't think this works if the property is defined by Ant's <property> task.

Example
========
BUILD.XML:
<project name="test_blank_space" basedir="." default="default">
    <property file="build.properties"/>
    <target name="default">
        <echo message="${message}Line2"/>
    </target>
</project>

BUILD.PROPERTIES:
message=Line1\n

OUTPUT:
Buildfile: build.xml

default:
     [echo] Line1
Line2

BUILD SUCCESSFUL

Total time: 1 second


>>> toomeykh@yahoo.com 01/04/02 10:19AM >>>
Hi,

I have a mail task configured as such:

<target name="build_success_message" depends="init">
<mail from="BuildMachine" 
      subject="A successful build"
      mailhost="this.that.com" 
      message="${buildMessage} Please see http://host/output/build.jsp
for more information." 
      tolist="toomeyk@bigfoot.com" />
</target>

buildMessage is created at run-time. Is there a way to get a newline
between buildMessage and "Please see....."

Thanks,
Kevin

__________________________________________________
Do You Yahoo!?
Send your FREE holiday greetings online!
http://greetings.yahoo.com

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

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message