External diff programs

5 views
Skip to first unread message

radic...@gmail.com

unread,
Jul 19, 2008, 3:13:33 AM7/19/08
to QBzr
Hi,

Alexander invited me to this discussion to talk about how I see
external diff working in QBzr.

This is how I would like it to work:

I think it would be nice if QBzr added an extra tab to the qconfig
window called "Diff Viewer". There would be a checkbox on this page
"Use built-in diff viewer". There would also be a text field where the
user could enter the name (and options) to pass to an external diff
program. When "Use built-in diff viewer" is selected this text field
would be disabled. When not selected the user could type a command
into the external diff viewer text field.

In the command text field they could enter variables that would get
substituted for the file paths to be diffed. QBzr would substitute the
names of the files for these variables and then invoke the diff
command. e.g. %left and %right could represent the paths to the files
that should be shown on the left and right side of the external diff
program. eg

kdiff3 %left %right

Whenever QBzr wants to show the diff of a file it would always use the
external diff viewer if the user had configured one. This would make
me very happy ;-)

Let me know if something is not clear or you have other ideas on how
this should work...

Cheers,

Nick

Alexander Belchenko

unread,
Jul 19, 2008, 3:41:33 AM7/19/08
to QBzr

Alexander Belchenko

unread,
Jul 19, 2008, 4:24:00 AM7/19/08
to QBzr
Thank you for explanation. It's almost clear now.
Although I believe built-in qdiff is one of the killer feature of
QBzr, but it's possible to implement.
Just one question: should external diff be used when user run `bzr
qdiff`?

On 19 июл, 10:13, radicaln...@gmail.com wrote:

Nicholas Allen

unread,
Jul 19, 2008, 4:29:20 AM7/19/08
to qb...@googlegroups.com
I agree that the built-in viewer is really handy. But it would be good
to be able to configure an external viewer for advanced uses.

I think it would make sense to launch the external diff viewer if you
use qdiff on a single file (as the external diff viewer only supports
file diffs). If you do a diff on a directory or multiple files the
builti-in diff viewer could be used. But I don't have a strong opinion
on this so feel free to do whatever makes the most sense to you.

Cheers,

Nick

Alexander Belchenko

unread,
Jul 19, 2008, 5:03:20 AM7/19/08
to qb...@googlegroups.com
Nicholas Allen пишет:

>
> I agree that the built-in viewer is really handy. But it would be good
> to be able to configure an external viewer for advanced uses.
>
> I think it would make sense to launch the external diff viewer if you
> use qdiff on a single file (as the external diff viewer only supports
> file diffs). If you do a diff on a directory or multiple files the
> builti-in diff viewer could be used. But I don't have a strong opinion
> on this so feel free to do whatever makes the most sense to you.

Currently qbzr launch qdiff for one file in rare cases, but in most cases
diff work on entire tree. So this will complicate your use case.
I'm not sure this complication will be good.

Nicholas Allen

unread,
Jul 19, 2008, 6:14:48 AM7/19/08
to qb...@googlegroups.com
Another possibility would be to always launch the external diff (if
configured) when the user explicitly asks for the diff of a single file
(eg double clicking a file name in the commit window etc). Otherwise the
internal diff viewer would be used but the user could double click on
the header of a file in the internal diff viewer to launch the external
viewer for that file.

I think that would make sense - don't you?

Nick

Reply all
Reply to author
Forward
0 new messages