At 20:18 11/10/2001 +1000, Peter Donald wrote:
Just get the XSLT sheet to generate a list of files and then load it via
includesfile - or am I missing something?

My problem stems from the fact that I don't actually know where the file will be - nor how many separate file lists there will be.

To elaborate:

Within build.xml, my style task is something like this:

<style
    basedir="C:\dev\web\arpsfamily\src"
    destdir="C:\dev\web\arpsfamily\html"
    style="C:\dev\web\xslt\photogallery.xsl"
    extension=".html">
  <include name="**/_gallery.xsl"/>
</style>

(I'm at work and the original is at home so I may have made some syntactical errors, hope this doesn't confuse the issue.)

This style task currently finds and processes two separate photo galleries:

C:\dev\web\arpsfamily\src\cameron\camerons_gallery.xsl
output goes to C:\dev\web\arpsfamily\html\cameron\

C:\dev\web\arpsfamily\src\familyphotos\familyphotos_gallery.xsl
output goes to C:\dev\web\arpsfamily\html\familyphotos\

Currently I use a copy task like this to copy all the files across:

<copy
    todir="C:\dev\web\arpsfamily\html">
  <fileset
      dir="C:\dev\web\arpsfamily\src">
    <include name="*.jpg"/>
  </fileset>
</copy>

This copies all files reguardless of whether the generated html references them.

I've changed my generation XSLT to drop a list of required photo files - this file gets generated in the output directory:

C:\dev\web\arpsfamily\html\cameron\photos.lst
C:\dev\web\arpsfamily\html\familyphotos\photos.lst

Each photos.lst file lists the names of the photos to copy.

I can hard code a copy task for each one like this:

<copy
    todir="C:\dev\web\arpsfamily\html">
  <fileset
      dir="C:\dev\web\arpsfamily\src"
      includesfile="C:\dev\web\arpsfamily\html\cameron\photos.lst"/>
</copy>

however, this requires hard coding for each gallery and I'm trying to keep the build file as generic as possible.

Thanks in advance for your help,
Bevan.

--

"Programming is an Art Form that Fights Back"

Bevan Arps (bevan.arps@actfs.co.nz)
Senior OO Analyst, ACT Financial Systems

This communication  is confidential  to ACT  Financial  Systems  (Asia Pacific)  and is intended for  use only by the  addressee.   The  views and opinions  expressed in  this email  are the senders  own and do not represent  the  views  and  opinions of  ACT  Financial  Systems  (Asia Pacific).