[ANNOUNCE] Example Cogito Addon - cogito-bundle
Aaron Bentley
aaron.bentley at utoronto.ca
Sat Oct 21 00:33:38 BST 2006
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Petr Baudis wrote:
> Dear diary, on Fri, Oct 20, 2006 at 05:34:39PM CEST, I got a letter
> where Aaron Bentley <aaron.bentley at utoronto.ca> said that...
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> Jakub Narebski wrote:
>>> Aaron Bentley wrote:
>>>> In Bazaar bundles, the text of the diff is an integral part of the data.
>>>> It is used to generate the text of all the files in the revision.
>>>
>>> I thought that the diff was combined diff of changes.
>> It is. It's a description of how to produce revision X given revision
>> Y, where Y is the last-merged mainline revision.
>
> Aha, so by default a bundle can carry just a _single_ revision?
No, bundles contain 1 or more revisions. They contain all the ancestors
of X that are not ancestors of Y.
Only the diff from X to Y is shown, but the diffs for all other
revisions are present in the MIME-encoded section.
Consider these four revisions in a straight-line ancestry: a, b, c, d.
'a' is a common ancestor. b, c and d are the revisions that are missing
from the target repository.
A default bundle will contain
metadata for d
diff from a -> d in plaintext
metadata for c
diff from b -> c in MIME encoding
metadata for b
diff from a -> b in MIME encoding
To install b, the diff for a->b is applied to a. To install c, the diff
for b->c is applied to b. To install d, the diff for a -> d is applied
to a.
Doing a diff from a -> d instead of from c -> d introduces some
redundancy, of course. But we do that because we want an overview diff.
> That doesn't sound right either, because then it wouldn't make sense to
> talk about "combined" or "simple" diffs. So I guess sending a bundle
> really is taking n revisions at your side, bundling them to a single
> diff and when the other side takes it, it will result in a single
> revision?
No, it copies the revisions verbatim, and we are careful to avoid data loss.
> Hmm, but that doesn't sound right either, that's certainly no revolting
> functionality and seems to be in contradiction with previous bundles
> description. But if it doesn't squash the changes, I don't see how the
> combined diff can be integral part of the data. Sorry, I don't get it.
It's because there's no other diff in the bundle that produces 'd'.
>> I've attached an example of what a combined patch-by-patch bundle looks
>> like.
>
> But that's the one there's no UI to select? Or where is the combined
> diff?
That is the one that doesn't have UI to select it. I've attached a
normal bundle for comparison.
Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFFOVzR0F+nu1YWqI0RAkACAJ4z2SJZgelZLfhoFKhEZbmvRIXMjACfag+h
6j+5vvIeHt7xMZOvp6CUcPk=
=33G4
-----END PGP SIGNATURE-----
-------------- next part --------------
A non-text attachment was scrubbed...
Name: hello-world-default.patch
Type: text/x-patch
Size: 1884 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20061020/43584397/attachment.bin
More information about the bazaar
mailing list