A fileset has a common base directory. There are no nested filesets.
Have you had a look at <path>s?

There are some tasks which dont support <path>s, and <copy> is one of them [1] 
- oh, there
was some work ... maybe a nightly build would work :-)

Alternatively you could iterate over filesets 
  <for param="fs.id" list="foodir,bardir">
      <sequential>
          <copy todir="...">
              <fileset refid="@{fs.id}"/>
          </copy>
      </sequential>
  </for>


Jan

[1] http://issues.apache.org/bugzilla/show_bug.cgi?id=20635



>-----Ursprüngliche Nachricht-----
>Von: Rick Mann [mailto:[EMAIL PROTECTED] 
>Gesendet: Samstag, 11. Juni 2005 02:15
>An: user@ant.apache.org
>Betreff: How to use multiple filesets with classpath AND copy
>
>Hi. I'm building a handful of Struts webapps, and would like to do  
>this in my build scripts:
>
>I want to specify a collection of .jar files from several different  
>directories, and I want to refer to the entire collection with a  
>single id. Now, I can make a fileset or filelist for a directory,  
>give it an ID and reference it in a classpath or a copy structure.  
>But I need to make two or three of these. I don't want my copy tags  
>or classpath tags to have to reference more than a single file- 
>structure ID.
>
>I need some kind of nested fileset. Is there any other way to do it?  
>I want the equivalent of the following (of course, using filelists or  
>whatever inside). Any ideas?
>
>
>
><fileset id="myFileSet">
>     <fileset dir="foodir">
>         <include name="log4j-1.2.8.jar"/>
>         <include name="lucene-1.4.2.jar"/>
>     </fileset>
>
>     <fileset dir="bardir">
>         <include name="something.jar"/>
>         <include name="somethingelse.jar"/>
>     </fileset>
></fileset>
>
>...
>
>
><classpath>
>     <fileset refid="myFileSet"/>
></classpath>
>
>
>...
>
><copy todir="${app.build}" preservelastmodified="true">
>     <fileset refid="myFileSet"/>
></copy>
>
>
>Thanks!
>
>
>-- 
>Rick
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to