> It might be worth investigating what is possible with items in msbuild
> and what use cases we can apply using this XPathObjectNavigator solution.
> John Lam posted some of his experiences using output items with msbuild
at:
> http://www.iunknown.com/000379.html
> Ian

I read that article and what I like about MSBuild (never tried it yet) is:
<Task Name="MSBuild"   Projects="..\lib\lib.proj">
   <OutputItem TaskParameter="TargetOutputs" Type="ReferencePath"/>
</Task>

transcribed into NAnt syntax something like (I use <exec> instead of <nant>
task here):
      <exec program="foo.exe" commandline="1 2 3">
         <resultitem taskoutput="output/resultcode" property="resultcode"/>
      </exec>

so <exec> task returns some semi-xml result (not xml in any form, just
XPathNavigatable objects) which you could reference in resultitem (or
outputitem) subelement (common for all tasks) and copy its value into
property.

This could be very simple to use in many cases. Still I want to keep
possibility to fetch all semi-xml document from task to for example iterate
with <xmlforeach> within failed projects:

    <solution configuration="Release" outputdir="${output.dir}"
includevsfolders="false">
        <projects>
            <includes name="${build.dir}/**/*.csproj"/>
        </projects>

         <resultitem id="solresult"/>
    </solution>
    <xml-foreach refid="solresult" xpath="failed/projects">
        ...
    </xml-foreach>

How you like this?


> > +1 for XPathObjectNavigator.  I was thinking about this myself.  W

Could we use XPathObjectNavigator.cs file from bamboo? Does our and their
licence allow that?
I'll do test implementation now to see how it'll be.

Martin



-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
_______________________________________________
nant-developers mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/nant-developers

Reply via email to