[MERGE] Output refactoring and XML integration into bzrlib

Aaron Bentley aaron.bentley at utoronto.ca
Mon Dec 10 23:54:04 GMT 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Martin Albisetti wrote:
> On Nov 29, 2007 3:59 PM, Aaron Bentley <aaron.bentley at utoronto.ca> wrote:
>> Perhaps you could expand on what bzr-eclipse uses it *for*?
> 
> bzr-eclipse uses the XML output to be able to interact with bzr
> without having any kind of binding or reading the FS. Just executes a
> bzr command to get whatever information is needed, parses it, and then
> does whatever magic it wants in eclipse itself.

So it does sound like you don't need to have more than one format for a
given kind of output.  Since it is parsing it, bzr-eclipse can control
how the data is displayed, and which data is displayed.

> PHP already has XML parsing functions natively, so if bzr provided XML
> by default, I could release into the wild the php<>bzr bit and not
> require users to install anything else.
> I can imagine thousands of use cases where it would be useful to have
> a machine-parseable output like XML to integrate it into other
> applications.
> And again, SVN has this natively.

This is all really beside the point.  No one is saying bzr shouldn't do
XML output.  (Though if SVN is doing it, maybe it's a bad idea :-)  All
I want is to make sure that if we add XML support, it isn't messy, it's
got good layering, and it doesn't interfere with programming Bazaar as a
commandline tool.

>> bzr has XML mostly in its storage formats.  For example, bzr revisions
>> are already stored as XML.  So your XML log is essentially doing a lossy
>> conversion from one XML format to another.  It seems redundant, and may
>> be counterproductive, since the XML logger may discard information you
>> later decide you want.
> 
> So you're saying we should be parsing the XML in the .bzr/ subdir?

No.  I'm saying that rather than invent a new XML representation for
revisions, it might make sense to use the existing format.

Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHXdGb0F+nu1YWqI0RAtDkAJ9j3D1FOgyfxZxbSW12jPkJAeFVSACfdg3g
Q73UtMwsYVKkIwI7qQvXvJM=
=3iYn
-----END PGP SIGNATURE-----



More information about the bazaar mailing list