Rod Ayers wrote:
Hi, all....
I'm trying to get a clear understanding of the impact of using
<include/>.
1. The contents of the included file makes the included code act as
if it was all part of one build file.
2. Tasks in the included file would be invoked with <call/>, rather
than <nant/> as with "separate" build files.
Note that there's nothing stopping you from doing both. Since the
include file must be a proper NAnt build file (i.e. with a <project>
element as the root element), you could invoke the included file via
<nant/> and you could, in the same build, invoke a target in the
included file via <call/>. You can even call the include file directly
from the command line. Of course, this wouldn't work sensibly unless
you were careful to design the files to work this way, but there is some
value in being able to invoke an include file directly via the command
line, if only to debug it.
There's also one thing you left out. Tasks in the included file can be
invoked via depends= attributes in the parent file. This is important,
since there are times when it's difficult to set up the control logic
that ensures a given task is only executed once, while the depends=
attribute handles that for you.
Gary
-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
NAnt-users mailing list
NAnt-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-users