bzr export/push with rsync
John A Meinel
john at arbash-meinel.com
Tue Nov 22 19:55:50 GMT 2005
William Dode wrote:
> Hi,
>
> It was a discussion some days ago to decide if push could also export
> the tree, i need this to let somes users to take a snapshot of the tree
> by rsync. What was decided finaly ?
>
> I could use the push plugin of bzrtools but now the commands have the
> same names ! What is the plan for bzrtools push ?
>
You could use my rsync plugin, which provides "rpush" and "rpull". It is
available from here:
http://bzr.arbash-meinel.com/plugins/bzr-rsync/
It needs to be cleaned up a bit, to make it a little bit safer. Right
now it uses the ".bzr/parent" location to determine if the trees are out
of date, which means that if you have a parent which is not the same as
your x-rsync-data location, you could accidentally overwrite things when
you aren't supposed to. The bzrtools plugin would download the
revision-history file using rsync, so it had to connect 2 times.
Also, whatever method you use, rsync will wipe out remote changes (we
don't do merging, just flat copying). Which is reasonable for some use
cases, but not the truly "correct" method.
At one point, I was also providing an rsync transport, which would allow
you to access the remote repository by spawning rsync as needed. It
would certainly be possible to clean it up, and enable it again. I just
didn't know if it was actually worth it. (Basically, it worked by
creating a temp directory where it would push/pull from, and then
spawned rsync to actually copy files back and forth, and then file
access was done locally)
If we fix it up and enable it again, then we would have another
transport for:
bzr branch rsync://host:path/to/files/
Basically, rsync://<normal rsync path> so a double colon means to
connect to an rsync server, paths follow the colon, so they are relative
to home, but if you start with / they are global, etc.
John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 249 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20051122/4201ef93/attachment.pgp
More information about the bazaar
mailing list