0

I am converting an existing batch script into a nant script.

the batch file originally made this call, which appears to copy all files with the same prefix to a directory.

xcopy /y /s "paths\name*.exe" Directory\

I know how to copy a folder tree in nant, but this is different. Is there a way to do this?

zalpha314
  • 1,444
  • 4
  • 19
  • 34

1 Answers1

0

Ok, I figured it out. I used this:

<copy todir="target\similars" >
    <fileset basedir="source\similars">
        <include name="similar*.txt" />
    </fileset>
</copy>

The wildcard * in the include element is what lets me specify differences in the filenames.

Eitan T
  • 32,660
  • 14
  • 72
  • 109
zalpha314
  • 1,444
  • 4
  • 19
  • 34