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

Re: diff summarize with wc path (was Re: [PATCH] svn diff --summarize)

From: Malcolm Rowe <malcolm-svn-dev_at_farside.org.uk>
Date: 2006-02-08 12:13:09 CET

On Tue, Feb 07, 2006 at 11:03:42PM +0000, Julian Foad wrote:
> Step 1: Allow X:BASE and BASE:Y summaries. This is easy: just resolve
> "BASE" to the actual number; "COMMITTED" and "PREV" are already supported
> in this way.
>

That sounds reasonable. Note that it has to deal with mixed-revision
wc's, so it's not a straight mapping to rN (though I guess that's true
for the other two keywords as well?).

What the wc-repos full diff does, for comparison, is to perform a trial
'svn up' to the requested revision, which gives us a BASE->repos diff and
the contents of the repository files in one go. It then uses that as a
guide to report the real diff (for repos->BASE, reversing the changes; for
repos->WORKING, recomparing the repository files to the WORKING files).

Note that there are some complexities with this approach, for example:
when diffing against WORKING, we need to rediff against BASE to determine
if there really was a change (or if the WORKING and repos versions were
the same, even though BASE wasn't); we may get propchanges in repos->BASE
and file content changes in BASE->WORKING, but we need to report them
together; and as previously mentioned, it's hard to reverse directory
deletes, since we don't get notified about the whole tree.

> Step 2: Implement a BASE:WC summary, performed without repository access.
> The API should also allow WC:BASE, though the user interface doesn't. As a
> hack to get this working, this could perhaps just call the full diff and
> discard the data.
>

(Note that the full diff is fairly broken for WORKING->BASE diffs,
precisely because we can't test them through the svn client.)

> Step 3: Allow X:WC and WC:Y summaries, probably by combining the info from
> (1) and (2).
>

While bearing in mind that you can't just combine the summary results,
since the change in N:BASE might be undone by the change in BASE:WORKING.

Regards,
Malcolm

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Feb 8 12:13:34 2006

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.