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

Question regarding svn_ra_do_update and delta data

From: Ph. Marek <philipp.marek_at_bmlv.gv.at>
Date: 2005-12-09 07:42:40 CET

Hello everyone,

I've stumbled upon a problem and would like to get some hints.

The problem is:
- I've local files, which I knew at which version they've been when checking
out.
- They are changed.
- I have no original full-text available.
- I'd like to update them.

Currently I just do an svn_ra_do_update() and receive the tree diffs as usual
- new files, deleted files, and so on.
But if a file has changed locally *and* in the repository - what should I do?
I tried to give /dev/null or an empty stringbuf as source for
svn_txdelta_apply; but that gives me "Delta source ended unexpectedly".

Is there a way to receive text updates in full, ie. not as a diff, for some
files in an update-operation?

I know that there's svn_ra_get_file(); but I may not call that while doing an
update on the same session, and I cannot stop the session in the middle, so
I'd have to have a second session open for that.

Alternatively I had the idea of doing svn_ra_do_status(), remembering which
files are to be updated, and then either
- do svn_ra_get_file() on them (which is easy but slow), or
- do svn_ra_do_update() and pass a carefully crafted report about the local
revisions, where the changed files do not exist yet.

I'm not sure if the second variant would be possible in every case - I can
think about lots of cases where I wouldn't know how to specify that all files
in this directory are at rev. X, but that single file does not exist yet.
After all, I cannot simply pass rev. 0 for the file, as the directory
structure didn't exist at this revision ...

Help, please.
Is there any way to get full-text data instead of diffs in update?
Thank you for your hints.

Regards,

Phil

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Dec 9 08:09:32 2005

This is an archived mail posted to the Subversion Dev mailing list.