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

Re: Custom merge/diff tool feature request

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: 2005-07-28 02:20:41 CEST

C. Michael Pilato wrote:
> Aaron Hillegass <info@bignerdranch.com> writes:
>
>>But, what I really want is a way to configure subversion to use my
>>custom diff/merge for a given file type. I want a way to say: "For
>>any file with a .sql extension, use sql_diff instead of the standard
>>line-based merge/diff".
>
> We've seen requests like this before. And until a week ago, I was
> even +1 on the idea. But no more.

So was I.

>
> Subversion needs only to do the following:
>
> - *always* call the external diff/diff3 program when those have
> been customized (via --diff[3]-cmd or the runtime configuration
> area), instead of automatically ruling out diffs on "binary"
> files.

Excellent proposal. +1 on that instead.

>
> - ensure that the temporary files passed to the external diff tool
> have predictable, documented naming schemes.

Did you mean instead,

   - ensure that the called program has a deterministic way to access the
Subversion working copy (if applicable) and repository URL associated with each
target file.

? I hope so. Based on what you say below, I think so.

> This would allow folks to write a script used as the value of
> --diff-cmd which can determine the input file's type either by its
> file extension or by asking Subversion about the mimetype, and then
> call the *real* program of your choosing.

[...]
> I'd prefer if the values of the
> --diff[3]-cmd options were format strings:
>
> diff-cmd = /my/diff/program --left %L --right %R --mime-type %M

That would have been good for the status quo or if Subversion were to call
different diff programs for different files, but after your proposal above,
every diff will be handled by the same script, so there is no longer any need
for the calling convention to be customisable. Just invent a calling
convention like we do for the repository hook scripts.

- Julian

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Jul 28 02:22:09 2005

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.