Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > ANT: Howto process each file in fileset

Reply
Thread Tools

ANT: Howto process each file in fileset

 
 
swebb99@gmail.com
Guest
Posts: n/a
 
      03-02-2006
Hi,

Is it possible to does some processing on each file in a filelist ?

What I want to do is perform checksum on each file in a directory and
compare the results with associated md5 files in another directory (or
do they always have to be in the same directory?). I can't figure out
how I can do this as checksum appears to compare all checksums of all
files in a directory and sets a property based on all files. I want to
process one at a time. I need some way of looping round each file and
basically doing some extra processing of the checksum doesn't match.

Cheers

Steve

 
Reply With Quote
 
 
 
 
Tony Morris
Guest
Posts: n/a
 
      03-03-2006
http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:
> Hi,
>
> Is it possible to does some processing on each file in a filelist ?
>
> What I want to do is perform checksum on each file in a directory and
> compare the results with associated md5 files in another directory (or
> do they always have to be in the same directory?). I can't figure out
> how I can do this as checksum appears to compare all checksums of all
> files in a directory and sets a property based on all files. I want to
> process one at a time. I need some way of looping round each file and
> basically doing some extra processing of the checksum doesn't match.
>
> Cheers
>
> Steve
>


It is certainly possible, only that there is not a core task that will
do it. Writing your own Ant task is quite simple.
I wrote one for JTiger - the 2 relevant source files are:
JTigerTask.java http://jtiger.org/test-coverage-report/_files/e.html
Fixtures.java http://jtiger.org/test-coverage-report/_files/d.html

--
Tony Morris
http://tmorris.net/
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
FAQ 6.14 How do I process each word on each line? PerlFAQ Server Perl Misc 0 04-08-2011 04:00 AM
FAQ 6.14 How do I process each word on each line? PerlFAQ Server Perl Misc 0 01-26-2011 11:00 PM
ant - using fileset for classpath and copy task Andrew McGhie Java 3 02-07-2008 03:07 AM
Ant - <fileset> problem? tonywinslow1986@gmail.com Java 2 02-10-2007 06:35 PM
ant jar/fileset propblems Miguel De Anda Java 1 07-03-2003 10:57 PM



Advertisments