ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claudio Corsi <cco...@exceloncorp.com>
Subject Re: Question about properties and ant2
Date Tue, 11 Sep 2001 19:34:44 GMT
> From: Peter Donald <donaldp@apache.org>
> 
> sorta. Theres two issues in that. Are properties immutable (ie unable to be 
> changed) ? and will "configuration" of tasks pick this up? The first issue 
> (ie making properties mutable rather than immutable) had no clear consensus 
> IIRC. The second issue is mostly true of current ant *except* in certain rare 
> occurences (when the same task is executing multiple times - like from a 
> script but property values have changed). We will just fix this minor and 
> rare case and thus allow easier manipulation of ant systems from your 
> favourite scripting language (javascript/python/whatever).
> 

This said, then how would I go about including a variable within the xml file
that is immutable and can be used throughout the xml file? If this does not
exist, can something like this be implemented? This can be for ant1 or ant2.

The reason is that I have a project that includes multiple targets that perform
the same tasks but that certain variables are different for each task. I
thought of creating a single target that is called by the other targets. This
target uses properties to determine how to run the given target. 

The reason behind the implementation of these targets is that our xml file is
starting to become large. I started to refractor the xml file to make it
simpler to add new targets without adding too much to the xml file. This is
where this idea came from and I really believe that this concept should be
added if not already their.

--Claudio


> > I know that with ant 1.3 and 1.4 I get the following:
> >
> >  common.property=foo_property
> >  common.property=foo_property
> 
> Yep. Not sure 100% on what Ant2 will do here though.
> 
> -- 
> Cheers,
> 
> Pete
> 
> --------------------------------------------------
>  The fact that nobody understands you doesn't 
>  mean you're an artist.
> --------------------------------------------------
> 

Mime
View raw message