[MERGE] Updated gcommit window
John Arbash Meinel
john at arbash-meinel.com
Fri Oct 26 16:31:13 BST 2007
-----BEGIN PGP SIGNED MESSAGE-----
The attached patch enhances the "gcommit" window with a few new details.
First, it always shows the full tree diff in the right hand pane. When
selecting a specific file on the left hand side, it will show just the diff for
It also allows using ^N to jump to the Next file.
It also has some basic support for adding a per-file commit message. Which will
then be shown in "bzr viz" and "bzr gannotate".
To enable the per-file commit data, you need to set "per-file-commit = True" as
a branch config. (So you can set it globally in ~/.bazaar/bazaar.conf, or in
locations.conf for specific branches, or in branch.conf.)
As an added bonus, I found that you can indeed write simple unit tests for
pygtk. It seems you don't have to have the main loop running in order to
interact with the widgets and have them issue events.
So I'm able to create a tree, and then make sure the different boxes are
populated with the right data. As well as ensure that selecting a given item
updates the other widgets correctly.
This also adds some refactoring of the DiffDialog, to create a DiffView which
can be embedded in both "bzr gdiff" and "bzr gcommit" windows.
I'm happy to refine it a bit if people so desire. But overall I think it is a
genuine improvement over the previous gcommit window.
There are some other small things, like using Tree._iter_changes instead of
Tree.changes_from, which means things are sorted by path, rather than being
sorted by action. (changes_from sorts into 'added', 'removed', etc.)
Also, I pushed this branch up to Launchpad, it should be available at:
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
More information about the bzr-gtk