Hey Mike,

This is now fixed in CVS. You'll need to update both NAnt and NAntContrib
for this fix.

Let me know if you want me to upload new nightly builds (as these aren't
done automatically anymore).

Gert

-----Original Message-----
From: Mike Frederick [mailto:[EMAIL PROTECTED] 
Sent: donderdag 6 november 2008 4:39
To: nant
Subject: [NAnt-users] Bug found - interaction of NAnt and NAntContrib

All,

I stumbled into this one today.  If you use a <fileset> task by itself 
in a target, all is ok; but if you put that task inside of a <choose> it 
fails.

Example script:

<project name="a">
    <property name="deploy.root" value=""/>
    <target name="go">
        <choose>
            <when test="${string::get-length(deploy.root)==0}">
                <fileset id="deploy.clean.fileset" basedir="${deploy.root}">
                    <include name="**\*.*"/>
                </fileset>
            </when>
            <otherwise>
                <echo>In the OTHERWISE</echo>
            </otherwise>
        </choose>
    </target>
</project>

Here is the output:

C:\build\Titan>nant -f:a.build go
NAnt 0.86 (Build 0.86.2898.0; beta1; 12/8/2007)
Copyright (C) 2001-2007 Gerry Shaw
http://nant.sourceforge.net

Buildfile: file:///C:/build/Titan/a.build
Target framework: Microsoft .NET Framework 2.0
Target(s) specified: go

go:

BUILD FAILED

C:\build\Titan\a.build(6,6):
Unknown task <fileset>.

Total time: 0 seconds.

Doesn't matter if you put the <fileset> in the <when> or the 
<otherwise>, you always get "Unknown task <fileset>."  Remove the 
<choose> altogether and it works fine.  I'm using Windows XP SP2, you 
can see the version of NAnt in the output and the newest available 
NAntContrib.

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great
prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
NAnt-users mailing list
NAnt-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-users

No virus found in this incoming message.
Checked by AVG - http://www.avg.com 
Version: 8.0.175 / Virus Database: 270.8.6/1765 - Release Date: 11/3/2008
4:59 PM


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
NAnt-users mailing list
NAnt-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-users

Reply via email to