[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: Philip Martin <philip_at_codematters.co.uk>
Date: 2005-06-09 19:00:40 CEST

"Martin Hauner" <Martin.Hauner@gmx.net> writes:

> Philip Martin wrote:
>> Martin Hauner <martin.hauner@gmx.net> writes:
>>
>> > - if it is a folder or a file
>>
>> A modified item has two types, before and after, they might not be the
>> same.
>
> Ok, we can add another type so have a before and after type.

Thinking again, I might be wrong here--it all depends on how you
intend to handle an item being replaced.

>> > (it doesn't make sense to run a visual
>> > diff on a folder)
>>
>> Why not? One could generate two text files containing the directory
>> contents, one item per line, sort them and then run a textual diff to
>> show items added and deleted. Property changes make as much sense on
>> directories as they do on files.
>
> Wouldn't i need the info file/dir in your case too?

Yes. I don't think I claimed otherwise?

> My point was that
> you would have to know if it is file or folder to decide how to run a
> diff on that item.

Agreed, but that's not quite the same as your original claim which was
that visual directory diffs don't make sense.

>> > - its mime type (the gui could decide based on the mime type which
>> > diff tool to run, ie. binary or text)
>> >
>> >
>
>> > There is currently no way to get a diff preview from the svn api.
>>
>> Do you mean the libsvn_client API? The libsvn_ra API allows it if you
>> write an appropriate svn_delta_editor_t, although it does have to
>> handle text-deltas.
>
> Yes, libsvn_client. Change that to: there is currently no >easy< way.. :)
>
> I don't know how much effort is necessary to create an svn_delta_editor_t.
> Is it an easy task?

Much the same as svn_wc_diff_callbacks2_t, but driving the RA layer
might be a bit more work.

-- 
Philip Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Jun 9 19:01:39 2005

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