monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Monotone-devel] Packets or Packet I/O no longer works?


From: Nathaniel Smith
Subject: Re: [Monotone-devel] Packets or Packet I/O no longer works?
Date: Wed, 4 May 2005 10:39:26 -0700
User-agent: Mutt/1.5.9i

On Tue, May 03, 2005 at 04:58:47PM +0100, Will Robertson wrote:
> Thanks, Clemens,
>   Yes, I would be interested in seeing the TCL script, if only to avoid
> having to work it all out myself!!
> 
>   Being able to send "patches" this way, that incorporate history, is
> one of the main reason for me sticking with darcs (and I don't really
> feel like debating any other pros or cons just at the moment);  I'm
> afraid having to rely on full network access for sync'ing multiple
> repositories is a bit of a show-stopper for me.

Hmm, so all you want is the ability to say "take that revision and
that revision and that revision, and put them in a file"?  Yeah, that
should be quite straightforward to script up.  (Basically, for each
revision, use 'rdata' to get the revision packet, then run 'cat
revision' and parse out the new_manifest and old_manifest lines, then
run 'mdelta' to get the delta packet between them, then run 'cat
manifest' on each, scan through file-by-file, and for each file
mentioned on both sides with different hashes, use 'fdelta' on the two
hashes to get a file delta packet, and file files that are new in the
new revision, use 'fdata' to get a full file packet.)

(This will sometimes create full file packets when not strictly
necessary, e.g., when there are renames; but it hardly seems worth the
bother to do better in this case...)

>   Even Git seems promising in this regard, in-as-much as it's just a
> bunch of files, and rsync is just a file-transfer mechanism.

A monotone database is also just-a-file, and if you really want to
rsync it (dunno why you would, it doesn't take any less network
connectivity than netsync, and is less efficient), I bet it works
better than rsync'ing git repos :-).  (Because monotone's db stores
deltas, whereas currently in git, you have to transfer complete copies
of every changed file.)

-- Nathaniel

-- 
When the flush of a new-born sun fell first on Eden's green and gold,
Our father Adam sat under the Tree and scratched with a stick in the mould;
And the first rude sketch that the world had seen was joy to his mighty heart,
Till the Devil whispered behind the leaves, "It's pretty, but is it Art?"
  -- The Conundrum of the Workshops, Rudyard Kipling




reply via email to

[Prev in Thread] Current Thread [Next in Thread]