i'm not sure this helps but if the "*" appears before a "/" doesn't this mean
that it
refers to a directory in all cases?
frank
[EMAIL PROTECTED] on 01/31/2000 02:01:00 PM
Please respond to [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
cc: (bcc: Frank Starsinic/TMS)
Subject: RE: Objections against advanced directory scanning
"The scanner itself is in a helper class called DirectoryScanner. For now,
the only directory scanning related 'behaviour' in the Tasks are the
setIncludes, setExcludes and setDefaultexcludes (and of course a call in
the execute method)."
Excellent! molto +1's
"The '**' is needed to cater for the following situations:
1. match files in 1 directory, but not it's subdirectories. e.g.
/test/*.java which matches all .java files in the /test/ directory.
2. match files in 1 directory, and all (or a subset of) it's
subdirectories.
e.g. /test/**/*.java which matches all .java files in all directories under
/test/.
3. match directories on the leafs of the tree e.g. **/CVS/* which matches
all CVS directories and their files.
If you don't have an extra special character ('**') besides the usual '*'
and '?', it is impossible to cater for all described situations.
If you can show me how to do it without '**', please tell me. I would be
very grateful."
Infozip does this with a "recurse into directories' flag (-R), that is used
in combination with the mask to determine which files are selected.
Does the following cover things (it does as far as I can tell).
1) Includes="/test/*.java" recurse="false"
2) Includes="/test/*/*.java" recurse="true"
3) Includes="*/CVS/*" recurse="true"
--
dIon Gillard, Multitask Consulting
Work: http://www.multitask.com.au
Play: http://www.trongus.com
I've just returned from THE Java Programming Conference,
http://www.SoftwareSummit.com - be there next year