cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John Morrison" <john.r.morri...@ntlworld.com>
Subject RE: DirectoryGenerator source-oriented refactoring
Date Thu, 10 Jul 2003 12:08:18 GMT
> From: Sylvain Wallez [mailto:sylvain.wallez@anyware-tech.com]
> 
> Gianugo Rabellino wrote:
> 
> > Sylvain Wallez wrote:
> >
> >> And while we're at refactoring, what do you think of having separate 
> >> regexps for directories and files ? This would be really useful since 
> >> their respective naming rules are totally different. E.g. if I want 
> >> only .xml files, the regexp has to be "^[^.]*$|\.xml$", which looks 
> >> quite ugly when the file regexp would simply be "\.xml$".
> >
> > How do you plan to express that in the component configuration? I'm 
> > afraid it might start being overcomplicated...
> 
> Simple : instead of the "includes" and "excludes" parameters, we would 
> have "file-includes", "file-excludes", "dir-includes" and "dir-excludes".
> 
> As decoupling files and dirs will drastically simplify the expressions, 
> I like Joerg's proposal of using Ant-like wildcards, which would make 
> them even more simpler.
> 
> Thoughts ?

If it's to be generic, wouldn't something like leaves and nodes be better
than files and dirs?

I like the idea of the Ant-like wildcards (globbing?), but I'd wish to
retain the power of regex - could it be optional?  Or have two generators
DirectoryGlobbingGenerator and DirectoryRegExGenerator?

J.

Mime
View raw message