Could you use a <fileset>?

Jan

> -----Ursprüngliche Nachricht-----
> Von: Al Le [mailto:al...@gmx.de]
> Gesendet: Donnerstag, 20. Oktober 2016 12:08
> An: user@ant.apache.org
> Betreff: How to delete all files in a dirset
> 
> Hello,
> 
> I have a dirset defined in my script. How can I delete all files
> contained in that dirset?
> 
> Actually, my goal is to delete the dirs from the dirset, including all
> the files contained in them. But since the delete task does not delete
> non empty dirs, I'd first delete all the files and, in a second call to
> 'delete', I'd delete the dirs.
> 
> But how can I delete the files?
> 
> I.e.
> 
> <!-- Define the set of dirs to delete so that id can be referenced by
> the id --> <dirset dir="${srcDir}" id="dirs.to.delete">
>     <include name="*_to-delete"/>
> </dirset>
> 
> <!-- Delete all the files contained in 'dirs.to.delete' --> <delete>
>     <!-- What should I specify here? --> <delete/>
> 
> Thanks!
> AL
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscr...@ant.apache.org For additional
> commands, e-mail: user-h...@ant.apache.org



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

Reply via email to