D
Dan Jones
I'm writing a script to process a directory tree of images.  In each
directory, I need to process each image and generate an HTML file listing
all of the images and links to the subdirectories.
Just about every source I can find on the 'net for processing subdirectories
points you at Find::Find.  However, I'm trying to do something like this:
enter directory
open INDEX, ".\index.html"
print INDEX HTMLheader
foreach file{
        if(file is an image){
                process file
                print INDEX FileInfo
        }
        else if(file is a directory){
                print INDEX directorylink
        }
}
print INDEX HTMLfooter
close INDEX
next directory
I need to be able to deal with a full file tree - multiple subdirectories
several levels deep.
As near as I can tell, Find::Find was not designed for this.  It's only
capable of running a command on each file, not processing files and file
names in batches as I'm trying to do.  Am I missing some of Find::Finds
capabilities?  Or do I need to roll my own functions for processing
subdirectories recursively?
directory, I need to process each image and generate an HTML file listing
all of the images and links to the subdirectories.
Just about every source I can find on the 'net for processing subdirectories
points you at Find::Find.  However, I'm trying to do something like this:
enter directory
open INDEX, ".\index.html"
print INDEX HTMLheader
foreach file{
        if(file is an image){
                process file
                print INDEX FileInfo
        }
        else if(file is a directory){
                print INDEX directorylink
        }
}
print INDEX HTMLfooter
close INDEX
next directory
I need to be able to deal with a full file tree - multiple subdirectories
several levels deep.
As near as I can tell, Find::Find was not designed for this.  It's only
capable of running a command on each file, not processing files and file
names in batches as I'm trying to do.  Am I missing some of Find::Finds
capabilities?  Or do I need to roll my own functions for processing
subdirectories recursively?