[RFC] Push via e-mail?

Jan Hudec bulb at ucw.cz
Sun Feb 19 08:52:43 GMT 2006


On Sun, Feb 19, 2006 at 09:21:37 +0100, Erik Bågfors wrote:
> 2006/2/19, Alexander Belchenko <bialix at ukr.net>:
> > I need to organize cooperative work with my co-worker. Unfortunately he
> >   cannot use bzr itself for push and pull changes. We may use only e-mail.
> > I'd like to know is there possible to create plugin for pushing changes
> > from one to other (assume that branches not diverged) via e-mail?
> >
> > I suppose this plugin should prepare archive (zip or tar.gz) with all
> > needed info for pushing: new items from revision-store, new and updates
> > items from weave-store and probably new inventory.weave? And when such
> > archive will be received via e-mail on another end plugin should
> > implement pull operation based on this data.
> >
> > Any hints how to implement this behaviour?
> 
> This is planed. See http://bazaar.canonical.com/SubmitByMail
> 
> (and of course, Johns answer)
> 
> I think something like this should be built into bzr sooner or later. 
> I my mind, The following commands
> cd branch1
> bzr submit /tmp/foo
> cd ../branch2
> bzr apply /tmp/foo
> 
> Should produce the exact same thing as
> cd branch2
> bzr merge ../branch1
> 
> But the first case is easier to mail or course :)
> This makes people that can't put up a branch somewhere, still be first
> class bzr citizens.

There is a small problem though (see Darcs, which does this). You need to
know /what/ to submit.

Darcs does it by refering to target repository -- which has the disadvantage,
that one of the repositories must be accessible to the other via network.

I am inclined to think, that in bzr submit should take a revision argument
instead. So you would say:

    bzr submit -r ancestor:../branch2.. /tmp/foo
                         ^^ Um, how does ancestor: specification work with
			 relative paths? If .. is a separator...

perhaps with a shorthand

    bzr submit --target ../branch2

equivalent to the above (and as side-efect memoizing the target).

This would have the advantage, that you could say:

    bzr submit -r 1526.. /tmp/foo

if you can't access the target, but know what you need to send by other
means.

It should also allow for something like:

    bzr submit --target http://bazaar-ng.org/bzr/bzr.dev \
	--mail bazaar-ng at lists.canonical.com

which would invoke a mail client to actually send the submission.
And with a bit of magic

    bzr submit --mail

    (which would use recorded target and read mail from that target's
    config)

Perhaps even most dwimmy

    bzr submit --target http://bazaar-ng.org/bzr/bzr.dev \
	bazaar-ng at lists.canonical.com

with remembering reducing to

    bzr submit

-- 
						 Jan 'Bulb' Hudec <bulb at ucw.cz>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060219/0306f4c4/attachment.pgp 


More information about the bazaar mailing list