monotone-devel
[Top][All Lists]
Advanced

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

Re: [Monotone-devel] Re: Doing a diff between branches


From: Nathaniel Smith
Subject: Re: [Monotone-devel] Re: Doing a diff between branches
Date: Wed, 13 Apr 2005 20:13:46 -0700
User-agent: Mutt/1.5.8i

On Wed, Apr 13, 2005 at 10:19:05PM +0100, Bruce Stephens wrote:
> Ah, you're right.  I was looking at "monotone diff --help", which does
> list this, but the real documentation has:
> 
> monotone diff
> monotone diff pathname...
> monotone diff --revision=id
> monotone diff --revision=id pathname...
> monotone diff --revision=id1 --revision=id2
> 
> So I think it's just the documentation that's not quite right, since
> it seems to work.

Whoops, you're right, this didn't use to work, but Derek fixed it.
Docs fixed now.

> I think there's a trickiness about accessing the same repository
> simultaneously with more than one client; maybe that could be hacked
> up by giving the web application its own copy of the repository, and
> only allowing push to it, and carefully protecting it (or maybe only
> allow pull from it, under the control of the app?).  However, there's

This isn't too hard a problem.  Give the webserver its own copy of
the repo, that it works against.  You have to do some sort of locking
to prevent the server accessing this repo at the same time as a pull
is running.  There are lots of approaches; the simplest is probably to
copy the repo to a temporary file, pull to the temporary file, and
then "lock" the repo, rename the temporary file on top of it, and
"unlock" it again.  "Lock" here means do whatever you have to cause
any web access to block while the lock is present... some sort of
basic read/write locks would work.  This kind of thing is always a
little annoying to deal with, but there are lots of approaches that
work, depending on context...

-- Nathaniel

-- 
"But in Middle-earth, the distinct accusative case disappeared from
the speech of the Noldor (such things happen when you are busy
fighting Orcs, Balrogs, and Dragons)."




reply via email to

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