Import checks if the file has already been
imported:
So importing the current build file would import it
once.
The following import.xml:
<project>
<echo>Hello World</echo>
<import file="import.xml"/>
</project>
Using ant -f import.xml prints out "Hello World" twice.
Note that one can still cause infinite loops with
antcall:
<project default="x">
<target name="x">
<antcall target="y"/>
</target>
<target name="y">
<antcall target="x"/>
</target>
</project>
Peter
On Wednesday 03 September 2003 11:42, Stefan Bodewig wrote:
> On 3 Sep 2003, <[EMAIL PROTECTED]> wrote:
> > Throw an exception instead of looping forever in top-level <*ant*>
> > task.
>
> does <import> need the same treatment? What happens if a build file
> tries to import itself?
>
> Stefan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]