Oh, sorry not sure about that. I usually use the **/* version and it works
as I 
thought it should.
Let´s have a look at the sources of patternset [1] ... okay -
PatternSet.NameEntry just
holds the name value. Evaluation is done in the DirectoryScanner [2]. There
it´s written
that name/ is name/** (private static String normalizePattern(String)). 

Mmh - "protected boolean isIncluded(String name)" does a simple comparison
of the 
current filename with all registered patterns. So it should be a different
meaning between
**/* and **   .


Jan


[1]
http://cvs.apache.org/viewcvs.cgi/ant/src/main/org/apache/tools/ant/types/Pa
tternSet.java?view=markup
[2]
http://cvs.apache.org/viewcvs.cgi/ant/src/main/org/apache/tools/ant/Director
yScanner.java?view=markup


> -----Ursprüngliche Nachricht-----
> Von: Douglas Kramer [mailto:[EMAIL PROTECTED]
> Gesendet am: Mittwoch, 9. Februar 2005 08:40
> An: Ant Users List
> Betreff: Re: AW: copy all but exclude one directory
> 
> Thanks.
> 
> Is there a difference between these two sets:
> 
>          <include name="**/*" />
>          <include name="**" />
> 
> -Doug
> 
> [EMAIL PROTECTED] wrote:
> > BACKUP is a file
> > BACKUP/ or BACKUP/** is a directory
> > 
> > Jan
> > 
> > 
> >>-----Ursprüngliche Nachricht-----
> >>Von: Douglas Kramer [mailto:[EMAIL PROTECTED]
> >>Gesendet am: Dienstag, 8. Februar 2005 22:37
> >>An: Dominique Devienne
> >>Cc: Ant Users List
> >>Betreff: Re: copy all but exclude one directory
> >>
> >>Thanks, that works.
> >>
> >>I'll submit a request to document that <exclude> works
> >>to exclude only the specified files or directories -- that is,
> >>it must name all the files to exclude, not just a top-level
> >>directory.
> >>
> >>BTW, what's the reason that these are not equivalent:
> >>
> >>        <include name="**/*" />
> >>
> >>
> >>        <include name="**" />
> >>
> >>
> >>-Doug
> >>
> >>(It looks like including files below BACKUP is stronger
> >>than excluding the top-level directory BACKUP)
> >>
> >>Dominique Devienne wrote:
> >>
> >>>>From: Douglas Kramer [mailto:[EMAIL PROTECTED]
> >>>>              <exclude name="BACKUP" />
> >>>
> >>>Use              <exclude name="BACKUP/**" />
> >>>
> >>>--DD
> >>
> >>------------------------------------------------------------
> ---------
> >>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