do not pretend to lock static-http repositories (issue994)

This commit is contained in:
Martin Geisler 2008-09-08 11:32:53 +02:00
parent 1343a1f47c
commit ca8bba4890
3 changed files with 13 additions and 0 deletions

View File

@ -74,6 +74,9 @@ class statichttprepository(localrepo.localrepository):
def local(self):
return False
def lock(self, wait=True):
raise util.Abort(_('cannot lock static-http repository'))
def instance(ui, path, create):
if create:
raise util.Abort(_('cannot create new static-http repository'))

View File

@ -49,6 +49,12 @@ echo '[hooks]' >> .hg/hgrc
echo 'changegroup = python ../printenv.py changegroup' >> .hg/hgrc
http_proxy= hg pull | sed -e 's,:[0-9][0-9]*/,/,'
echo '% trying to push'
hg update
echo more foo >> bar
hg commit -m"test" -d "100000000 0"
http_proxy= hg push | sed -e 's,:[0-9][0-9]*/,/,'
echo '% test with "/" URI (issue 747)'
cd ..
hg init

View File

@ -29,6 +29,10 @@ adding manifests
adding file changes
added 1 changesets with 1 changes to 1 files
(run 'hg update' to get a working copy)
% trying to push
1 files updated, 0 files merged, 0 files removed, 0 files unresolved
abort: cannot lock static-http repository
pushing to static-http://localhost/remote
% test with "/" URI (issue 747)
requesting all changes
adding changesets