--- DONNIE HALE <[EMAIL PROTECTED]> wrote:
> That makes sense. The only hitch is that my "determining property" is an
> environment variable. So, as you say, I have to jump through a bunch of
> <conditional> hoops to turn that into one of several different
> properties for a <target>'s "if".
> 
> Might I propose that this would be much simpler if <target> had this
> construct:
> 
> <target name="..." depends="..." if="prop.name" equals="prop.value">
>   ...
> </target>

That you won't get -- it's been proposed many times before, and thoroughly
rejected each time.

But, as Steve pointed out, using property files is the way to simplify the
whole thing for you (should've thought of that myself, but brain's not
working too good with this nasty cold)... So, once you have your props
files, you'd just need a single target to figure out which file to read in
and then read that one in. Eg:

  <target name="setProps">
    <condition property="propsFile" value="val1.properties">
      <equals arg1="${determining_property}" arg2="val1"/>
    </condition>
    <condition property="propsFile" value="val2.properties">
      <equals arg1="${determining_property} arg2="val2"/>
    </condition>
    ...
    <property file="${propsFile}"/>
  </target>

Diane


=====
([EMAIL PROTECTED])



__________________________________________________
Do You Yahoo!?
Check out Yahoo! Shopping and Yahoo! Auctions for all of
your unique holiday gifts! Buy at http://shopping.yahoo.com
or bid at http://auctions.yahoo.com

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

Reply via email to