[MERGE] dpush / foreign vcs testing

Jelmer Vernooij jelmer at samba.org
Sun Feb 1 00:52:42 GMT 2009

Hi Ben,

On Sun, 2009-02-01 at 11:17 +1100, Ben Finney wrote:
> Jelmer Vernooij <jelmer at samba.org> writes:
> > Since this has the consequence that it doesn't preserve revision ids
> > or file ids the local and the remote branch will have diverged after
> > a dpush operation - breaking a basic invariant of regular push. To
> > work around this, dpush can "rebase" (the actual operation is much
> > simpler) the local branch on the remote branch afterwards.
> What implication does this have for “downstream” branches?
> For example::
>     $ bzr get svn://example.com/repository/branch/ upstream/
>     $ bzr branch upstream/ feature-foo/
>     $ cd upstream/
>     $ # hack hack
>     $ bzr commit
>     $ bzr dpush --resync   # or whatever the “rebase-but-simpler” option is
>     $ cd feature-foo/
>     $ bzr pull             # will this succeed? why or why not?
Yes, this will succeed. Only the revision id of the revision that was
pushed to svn was changed.

>     $ # hack hack
>     $ cd ../upstream/
>     $ bzr merge ../feature-foo/
This will say "Nothing to merge", as you didn't make any commits in
>     $ bzr commit
This will say "Pointless commit"
>     $ bzr dpush --resync
>     $ cd ../feature-foo/
>     $ bzr missing ../upstream/      # will this return a null set? why or why not?
In your exact example, that will return a null set. 

If you had committed a revision "revA" in feature-foo that you had
merged, then what you would see would depend on the foreign vcs. 

In the case of git, which supports multiple parents per revision
natively, you would see:
- mine(feature-foo): revA
- theirs(upstream): revA', merge'

In the case of svn, which does not support multiple parents per revision
(so dpush will only push the mainly), you would see:
- mine(feature-foo): revA
- theirs(upstream): merge'

FWIW, the "rebase-but-simpler" option is the default. You can disable
its behaviour using --no-rebase.



Jelmer Vernooij <jelmer at samba.org> - http://samba.org/~jelmer/
Jabber: jelmer at jabber.fsfe.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 315 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20090201/d2f4785e/attachment.pgp 

More information about the bazaar mailing list