David,
--- David Resnick <[EMAIL PROTECTED]> wrote:

> I'm trying to include a list of files to delete in a
> text file which is read
> into a property (with properties expansion) and then
> used in the includes
> property of a fileset in a delete task. For some
> reason when there are line
> breaks in the text file, this isn't working!
> 
>               <loadfile property="to.delete"
> srcFile="ant.delete.txt">
>                       <filterchain>
>                               <expandproperties />
>                       </filterchain>
>               </loadfile>
>               <delete quiet="false" verbose="true"
> includeEmptyDirs="true">
>                       <fileset dir="${dir.cab.work}"
> includes="${to.delete}" />
>               </delete>
> 
> If the list in the text file is separated by commas,
> it works fine.

I would recommend you to replace the line breaks in
your file with commas. I tried to do it with regular
expression, but I am not good at them. Here is my
unsuccessfull attempt:
  <loadfile property="to.delete"
srcFile="ant.delete.txt">
    <filterchain>
      <tokenfilter>
        Here we should do smth like that with regexps
but the line below does not work :((>
        <replaceregex pattern="${ls}" replace=","/>
      </tokenfilter>
      </filterchain>
  </loadfile>

I hope someone from regexp gurus will help you.

Regards Ivan


        
                
__________________________________ 
Celebrate Yahoo!'s 10th Birthday! 
Yahoo! Netrospective: 100 Moments of the Web 
http://birthday.yahoo.com/netrospective/

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to