[PLUGIN] Updated 'bzr-rsync'
John Arbash Meinel
john at arbash-meinel.com
Fri Aug 4 23:59:39 BST 2006
I've been working all this week on updating my 'bzr-rsync' plugin.
I created an official project for it on Launchpad
https://launchpad.net/products/bzr-rsync
Along with the official trunk branch:
http://bazaar.launchpad.net/~jameinel/bzr-rsync/trunk
I haven't updated all the documentation, but I spent all week working
out all of the corner cases of pushing using rsync.
* What does 'bzr-rsync' do?
It currently just provides the command 'bzr rpush'. This uses the same
push location as what is stored by 'bzr push', providing the same basic
functionality as 'bzr push', only it *also* will update the remote
working tree.
* Why is it better than just plain 'rsync'.
Well, it only pushes versioned files. It also supports a '.rsyncfilter'
file which lets you optionally add more files to be copied or ignored.
It supports standalone branches, and branches inside repositories. It
supports v5,v6, and metadir branches (knit and weave). It even supports
doing a push between branch types, just like regular 'bzr push'.
It also tries not to touch files that haven't been changed/unversioned
remote files. So that if you have some config files on the remote end it
will leave them alone (unless you supply --pristine)
In general 'bzr rpush' uses the built-in 'bzr push' functionality to
update the remote history, and then spawns rsync to update the remote
working tree. However, we all know that 'bzr push' is really slow with
weave-format branches. So if it comes across a standalone weave-format
branch, it will update the remote branch using rsync the whole way.
* What to do now:
I spent a lot of time writing test cases, but I may not have gotten
everything. Because 'rsync' can potentially delete your files, I ask
that you use caution, and try pushing to non-critical areas first.
However, with what I've done, I believe I've opened up a safe way to
push and update remote working trees.
Some of the work I've done is also generic enough that it could be used
for a plugin that uses bzr's Transports to overwrite the remote end with
new files. It probably wouldn't do fancy merging, or removing unknown
files, but it would be possible to push onto ftp (or sftp without rsync).
Probably the best way to get this used would be to get it merged into
bzrtools, since that seems to be the de-facto bundled bzr plugin.
Updating remote working trees has been asked for for quite some time. I
think this is a reasonable step along the way.
John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 254 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060804/ed53e400/attachment.pgp
More information about the bazaar
mailing list