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

Re: proposal: diff preview for gui client

From: Peter N. Lundblad <peter_at_famlundblad.se>
Date: 2005-06-18 22:43:11 CEST

On Sat, 18 Jun 2005, Martin Hauner wrote:

> Ben Collins-Sussman wrote:
> >
> > On Jun 12, 2005, at 2:23 AM, Martin Hauner wrote:
> >
> >> Philip Martin wrote:
> >>
> >>
> >>> [diff preview]
> >>> In the short term I suppose a new svn_wc_diff_callbacks2_t will
> >>> do, in the long term we might need a new RA function that tells us
> >>> which things have changed without sending the details of the changes,
> >>> i.e. no text-deltas (and maybe no property changes either).
> >>>
> >
> > IIUC, 'svn merge' is now doing exactly this in svn 1.2.
> > [..]
> > So in svn 1.2, cmpilato changed 'svn merge' to request one of our old-
> > fashioned tree-delta reports, one which we used to call a "skelta".
> > It's a tree-delta without any text-deltas, just a description of which
> > files need to be fetched. 'svn merge' now quickly sucks the whole
> > skelta into a tmpfile, then parses the skelta slowly, doing
> > svn_ra_get_file()'s as needed.
> >
> > So it sounds like we don't need a new RA function here at all, do we?
> > 'svn merge' is already doing this very thing, so it must be already
> > possible.
>
> Yes, it can be done without a new ra function.
>
> I created a new api function svn_client_diff_preview with a callback
> function svn_diff_preview_func_t. It uses a simple svn_delta_editor_t
> implementation as input to svn_ra_do_diff. So no new ra function.
...

But, as Philip implicitly points out, that will send you text deltas
(which you ignore, I guess). To be more efficient, you need a revised (see
HACKING) version of svn_ra_do_diff, with a parameter indicating whether to
send text deltas or not. We already have that functionality for
svn_ra_do_status, so I think it should be pretty straight-forward to
implement.

Best,
//Peter

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Jun 18 22:43:57 2005

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