--- "Wannheden, Knut" <[EMAIL PROTECTED]> wrote:
> you could just have the property defined in one properties file and
> undefined in the other.  i.e.
> 
> in default.properties
> test=true
> 
> in my.properties
> #test=true
> 
> and then
> 
> <target name="test" if="test">
>  ...
> </target>
> 
> Now you just have to load the properties file prior to calling the test
> target.

I'm afraid that wouldn't work, since (I assume) the idea is to read in
both my.properties and defaults.properties, with my.properties values
overriding (being read in first) those in defaults.properties -- so just
commenting out the targets in my.properties won't stop them from getting
defined by defaults.properties.

I think you (Tibor) need to re-think your approach. Instead of setting
target names to true and false and trying to "if" on the value, you should
just assume that all targets are run by default (ie., don't set any value
for them in defaults.properties, since it's not necessary, if they're all
"on" by default), then set "exclude.<target_name>" properties in
my.properties that you then 'unless' on in your <target>'s. For example:

#my.properties
exclude.test=true

----

  <target name="test" unless="exclude.test">
    ...
  </target>

Diane

=====
([EMAIL PROTECTED])



__________________________________________________
Do You Yahoo!?
HotJobs - Search Thousands of New Jobs
http://www.hotjobs.com

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to