ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Elaine Fortin <elaine_for...@harvard.edu>
Subject RE: Ant exec find -exec problem
Date Wed, 15 Nov 2006 19:55:47 GMT

Of course, that's a paste error. It should have read:
         <exec executable="find">
<arg line="./feeds -name myFilename* -mtime +10 -exec mv
'{}' ./feeds_backup \; "/>
         </exec>





At 11:35 AM 11/15/2006 -0800, you wrote:

>You may not put "find" in the <arg> part.
>
>
>-----Original Message-----
>From: Elaine Fortin [mailto:elaine_fortin@harvard.edu]
>Sent: Wednesday, November 15, 2006 11:21 AM
>To: user@ant.apache.org
>Subject: Ant exec find -exec problem
>Importance: Low
>
>
>I am trying to create an Ant script to move files that are 10 days old to a
>backup directory.
>I cannot find how to do this purely in Ant, but I know that the Unix 'find'
>works.
>
>Ant returns the error: "[exec] /bin/find: incomplete statement"
>
>when I issue the following:
>             <exec executable="find">
>                     <arg line="find ./feeds -name myFilename* -mtime +10 
> -exec mv
>'{}' ./feeds_backup \; "/>
>                 </exec>
>
>This command works fine when issued from a Unix shell:
>   find ./feeds -name myFilename* -mtime +10 -exec mv '{}' ./feeds_backup \;
>
>How can I make this work?
>
>Thanks,
>Elaine
>
>
>
>---------------------------------------------------------------------
>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