ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matt Benson <gudnabr...@yahoo.com>
Subject Re: AW: ANT resource selector examples
Date Thu, 30 Oct 2008 14:41:47 GMT
Sorry, I thought Peter had fixed things so that the ns
declarations were unnecessary.

-Matt

--- Jan.Materne@rzf.fin-nrw.de wrote:

> Based on Matts code here a working example:
> 
> <project>
>     <filelist id="allfiles" dir="${ant.home}/bin"
> files="ant.cmd,foo.txt,ant.bat,bar.txt,ant"/>
>     <restrict id="missingfiles">
>         <filelist refid="allfiles"/>
>         <rsel:not
>
xmlns:rsel="antlib:org.apache.tools.ant.types.resources.selectors">
>             <rsel:exists/>
>         </rsel:not>
>     </restrict>
>     <echo>These files are missed:
> ${toString:missingfiles}</echo>
> </project>
> 
> This should show
> 
> Buildfile: build.xml
>      [echo] These files are missed:
> YOUR_ANT_HOME\bin\foo.txt;YOUR_ANT_HOME\bin\bar.txt
> 
> BUILD SUCCESSFUL 
> 
> 
> 
> Jan
> 
> 
> >-----Urspr√ľngliche Nachricht-----
> >Von: Matt Benson [mailto:gudnabrsam@yahoo.com] 
> >Gesendet: Donnerstag, 30. Oktober 2008 15:14
> >An: Ant Users List
> >Betreff: Re: ANT resource selector examples
> >
> ><filelist id="myfilelist" dir="foo"
> >files="bar,baz,blah" />
> >
> ><restrict id="myexistingfiles">
> >  <filelist refid="myfilelist" />
> >  <not>
> >    <exists />
> >  </not>
> ></restrict>
> >
> >HTH,
> >Matt
> >
> >--- Eric Wood <EWood@llbean.com> wrote:
> >
> >> Can somebody point me to some examples on how to
> use
> >> resource selectors
> >> on filelists?  The manual page is a little terse
> and
> >> I having a hard
> >> time finding good examples. I trying to
> understand
> >> how to use <non> and
> >> <exists> to select non-existing files in the
> >> filelist.
> >>  
> >> Thanks, Eric
> >> 
> >
> >
> >
> >      
> >
>
>---------------------------------------------------------------------
> >To unsubscribe, e-mail:
> user-unsubscribe@ant.apache.org
> >For additional commands, e-mail:
> user-help@ant.apache.org
> >
> >
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> user-unsubscribe@ant.apache.org
> For additional commands, e-mail:
> user-help@ant.apache.org
> 
> 



      

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message