[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [Subclipse-users] svnClientAdapter - Determining if a Directory Needs Updates

From: Mark Phippard <markphip_at_gmail.com>
Date: 2007-03-09 22:06:38 CET

On 3/9/07, Zack Grossbart <zgrossbart@novell.com> wrote:
>
> This is an svnClientAdapter question.
>
> I am trying to programmatically determine if files and folders have
> updates
> available on the Subversion server svnClientAdapter. When I am handling
> an
> individual file I can compare the last changed revision of the ISVNInfo
> object
> from the server to the revision of the ISVNStatus of the local file. If
> the
> server info has a greater revision number than the local file then there
> are
> updates available.
>
> However, I'm having more of a problem with directories. When I look at
> the
> revision of the ISVNStatus object for a directory it is always less than
> the
> revision of the ISVNInfo object from the server. The last changed
> revision for
> directories appears to be associated with the last changed revision of the
> oldest file in that directory. It sort of feels like I'm missing
> something and
> there should be a better way to do this. Am I doing this the best way
> possible?
> Is there something better I should be doing?

You should just run the status API with the contact server option. It will
only return items that are out of date. Subversion will do the work for
you. You cannot really rely on the revision info and doing it yourself
because the Subversion API's do not return the correct information.

-- 
Thanks
Mark Phippard
http://markphip.blogspot.com/
Received on Fri Mar 9 22:06:47 2007

This is an archived mail posted to the Subclipse Users mailing list.