Ant fileset includes no classes -


I have a folder source with a subfolder be next Fileset should select all * .cls files under the yes folder, recursive! (Also the .cls files in subfolders of yes folder):

   & Lt; / Fileset & gt;  

Apparently the ant does not select a single file ...

If I do this I

   & Lt; / Fileset & gt;  

Ant selects all .cls files.

What is the difference between two snippets?

folder structure:

  • source
    • be
      • dirA
        • dirB
          • .cls Files
        • DIRC
          • .cls files

They both copy the file in different ways Are there.

Note that the "" directory root includes the first copy:

  ├── build.xml ├── sources │ └── be │ └── dirA │ ├── dirB │ │ ├── File1.cls │ │ └── file2.cls │ └── dirC │ └── file3.cls └── target ├── copy1 │ └── be │ └── DirA │ ├── dirB │ │ ├─ ─ file1.cls │ │ └── file2.cls │ └── dirC │ └── file3.cls └── copy2 └── dirA ├── dirB │ ├── File1.cls │ └── file2.cls └── dirC └─ ─ file3.cls  

build.xml

  & lt; Project name = "demo" default = "copy" & gt; & Lt; Property Name = "src.dir" location = "Source" /> & Lt; Property name = "build.dir" location = "target" /> & Lt; Target name = "copy" dependent = "copy 1, copy 2" & gt; & Lt; / Target & gt; & Lt; Target name = "copy 1" & gt; & Lt; Copy todir = "$ {build.dir} / copy1" & gt; & Lt; Fileset dir = "$ {src.dir}" & gt; & Lt; Include name = "be / ** / * .cls" /> & Lt; / Fileset & gt; & Lt; / Copy & gt; & Lt; / Target & gt; & Lt; Target name = "copy2" & gt; & Lt; Copy todir = "$ {build.dir} / copy2" & gt; & Lt; Fileset dir = "$ {src.dir} / be" & gt; & Lt; Include name = "** / * .cls" /> & Lt; / Fileset & gt; & Lt; / Copy & gt; & Lt; / Target & gt; & Lt; Goal name = "clear" & gt; & Lt; Delete dir = "$ {build.dir}" /> & Lt; / Target & gt; & Lt; / Project & gt;  

Comments

Popular posts from this blog

Member with no value in F# -

java - Joda Time Interval Not returning what I expect -

c# - Showing a SelectedItem's Property -