ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Don Taylor <>
Subject uptodate task not setting property properly
Date Wed, 11 Jul 2001 17:50:43 GMT
Hi all. Here's a task I'm executing:

<target name="checkForUpdates" if="server.update.available">
  <uptodate property="updates.notAvailable">
    <mapper type="glob" from="*" to="${parentdir}/*"/>
    <srcfiles dir="${server.update}"/>

What I'm trying to do is contact a server, ${server.update}, and
compare the set of files found there to the set of local files. There
is a one-to-one correspondence between the files.

Here's the deal: this works great on my machine (a Windows NT 4.0 SP6
box running Java 1.3.0-C). If I delete a local file,
${updates.notAvailable} is not defined, or if a local file is
out-of-date it is not defined. Perfect.

The problem is on a client's machine running Windows 95 and also
running Java 1.3.0-C. Of the couple dozen or so files that are checked,
a couple of them *always* say they're out of data. I've used the
verbose option to see what's going on, and all you see is that the file
was added because the local file was outdated. Of course if you look at
the file dates and times in explorer on both the client and the server
they are identical. Like I said, according to the log the task found
the *majority* of the files up to date, only a couple is it having
problems with.

I did check the source and found that ultimately the uptodate task
relies on SourceFileScanner.restrict(String[], File, File,
FileNameMapper) to do the heavy work. This method will ultimately
create a source and dest File object and then compare the results of
their File.lastModified() methods. I *did* check the Bug Parade to see
if there were any applicable issues with this method. I didn't find

So does anyone have any ideas?



Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail

View raw message