ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Diane Holt <hol...@yahoo.com>
Subject Re: Is this a desirable feature?
Date Tue, 22 May 2001 00:46:30 GMT
Oops -- undefined pronoun :)  Where I said "It was requested...", I'm
talking about recursive property resolution.

Diane

--- Diane Holt <holtdl@yahoo.com> wrote:
> --- "Headley, Bryan" <BHeadley@universalaccess.net> wrote:
> > Assume you can deploy to one of several environments. So you set up a
> > variable called 'build.for" that you can pass on the command line to
> > ant.
> >  
> > So, we're looking at,
> >  
> > <property name="app.DEV.deployment.dir" value="/opt/deployment/forDev"
> > />
> > <property name="app.QA.deployment.dir" value="/opt/deployment/forQa"
> />
> > <!-- fairly simplistic; I might actually use different template files,
> > etc
> > -->
> >     ...
> > <property name="app.deployment.dir"
> > value="${app.${build.for}.deployment.dir}"/>
> >  
> > Does anyone else see the benefit to a recursive propertyName parser?
> >  
> > There's been talk about an IF command; would that be a more acceptable
> > approach? Or am I merely insane?
> 
> It was requested but rejected for Ant2.
> 
> In your case, since you're passing a property on the command-line
> anyway,
> if you define it as -Dbuild.for="Dev", couldn't you just do:
> 
> <property name="app.deployment.dir"
>           value="/opt/deployment/for${build.for}"/>
> 
> and eliminate those other two properties altogether?
> 
> Diane

=====
(holtdl@yahoo.com)



__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices
http://auctions.yahoo.com/

Mime
View raw message