Ugh. OK, it almost works. It breaks again if 'master' doesn't depend on
'init' because then the init-complete property is only set for the scope of
one 'antcall'.
Any other suggestions?
L.
On 9/3/02 11:04 AM, "Laurie Harper" <zodiac@holoweb.net> wrote:
> Thanks, Stefan, that did the trick!
>
> L.
>
> On 9/3/02 2:22 AM, "Stefan Bodewig" <bodewig@apache.org> wrote:
>
>> On Mon, 02 Sep 2002, Laurie Harper <zodiac@holoweb.net> wrote:
>>
>>> <target name="init">
>>> <target name="worker" depends="init">
>>> <target name="master" depends="init">
>>> <antcall target="worker"><param name="x" value="y"/></antcall>
>>>
>>> Then running ant causes 'init' to be invoked 3 times. I only want it
>>> to be executed once.
>>
>> Guard against it with a property.
>>
>> <target name="init" unless="init-complete">
>> ...
>> <property name="init-complete" value="who cares?"/>
>> </target>
>>
>> Stefan
>>
>> --
>> To unsubscribe, e-mail: <mailto:ant-user-unsubscribe@jakarta.apache.org>
>> For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>
>>
>
>
> --
> To unsubscribe, e-mail: <mailto:ant-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>
>
--
To unsubscribe, e-mail: <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>
|