tags:

views:

75

answers:

0

We have the following piece of code in our nant script:

    <copy todir="Output">
        <fileset basedir="Build">
            <include name="Antlr.Runtime.dll" asis="true"/>
            ...

When this part is executed, it fails because it looks for Antlr.Runtime.dll in the project folder not in the Build folder as specified by the basedir attribute. When I remove asis (or set it to false which is default) then it uses the Build folder as expected. But when the file is not present it doesn't fail which I want.

I tried nant 0.85, 0.86 and 0.90 and there's no change in the behaviour. The only meaningful reference to this issue I found is this but no-one answered and the change doesn't seem to be implemented so far (it dates back to 2006).

Is this a correct behaviour? And if so, how can I use the basedir attribute and get an error if the file specified is not present?

Thanks