You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by "Anderson, Jeremy" <je...@amerisourcebergen.com> on 2002/09/12 20:32:22 UTC

ANT generated deployment script

I've looked through the documentation but found nothing.

Does ANT have the ability to write a file?  I'd like ANT to create a new deployment script after packaging and then mail package w/script.  Packaging/mailing are easy, but howto write the deployment script (possibly from a template?)


Thanks,

j.anderson


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: ANT generated deployment script

Posted by Jeff Turner <je...@apache.org>.
On Thu, Sep 12, 2002 at 03:54:00PM -0700, didge wrote:
> Use Texen.  See the velocity project.  I would subclass the TexenTask and
> override the populateInitialContext method to put the current project into
> the context, say with the key "ant".  This will allow you to create a very
> simple output file template, then populate with properties from your script.
> You'll be able to access any of your ant project's properties from within
> the template using "$ant.somePropertyName".

A fair approximation to that is:

<xmlproperty file="project.xml" collapseattributes="true"/>
<echoproperties prefix="project" destfile="tmp.properties"/>
<filter filtersfile="tmp.properties"/>
<copy file="script.sh" filtering="true" ... />


--Jeff

> didge
> 
> -----Original Message-----
> From: Anderson, Jeremy [mailto:jeranderson@amerisourcebergen.com]
> Sent: Thursday, September 12, 2002 11:32 AM
> To: Ant Developers List
> Subject: ANT generated deployment script
> 
> 
> I've looked through the documentation but found nothing.
> 
> Does ANT have the ability to write a file?  I'd like ANT to create a new
> deployment script after packaging and then mail package w/script.
> Packaging/mailing are easy, but howto write the deployment script (possibly
> from a template?)
> 
> 
> Thanks,
> 
> j.anderson

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: ANT generated deployment script

Posted by didge <di...@foundrylogic.com>.
Use Texen.  See the velocity project.  I would subclass the TexenTask and
override the populateInitialContext method to put the current project into
the context, say with the key "ant".  This will allow you to create a very
simple output file template, then populate with properties from your script.
You'll be able to access any of your ant project's properties from within
the template using "$ant.somePropertyName".

didge

-----Original Message-----
From: Anderson, Jeremy [mailto:jeranderson@amerisourcebergen.com]
Sent: Thursday, September 12, 2002 11:32 AM
To: Ant Developers List
Subject: ANT generated deployment script


I've looked through the documentation but found nothing.

Does ANT have the ability to write a file?  I'd like ANT to create a new
deployment script after packaging and then mail package w/script.
Packaging/mailing are easy, but howto write the deployment script (possibly
from a template?)


Thanks,

j.anderson


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>