##// END OF EJS Templates
peer: introduce peer methods to prepare for peer classes...
peer: introduce peer methods to prepare for peer classes This introduces a peer method into all repository classes, which currently simply returns self. It also changes hg.repository so it now raises an exception if the supplied paths does not resolve to a localrepo or descendant. Finally, all call sites are changed to use the peer and local methods as appropriate, where peer is used whenever the code is dealing with a remote repository (even if it's on local disk).

File last commit:

r14409:9ff996ba default
r17191:58848126 default
Show More
notcapable
19 lines | 519 B | text/plain | TextLexer
Steven Brown
tests: add script to disable a selected wire protocol capability...
r14011 # Disable the $CAP wire protocol capability.
if test -z "$CAP"
then
echo "CAP environment variable not set."
fi
cat > notcapable-$CAP.py << EOF
from mercurial import extensions, repo
def extsetup():
extensions.wrapfunction(repo.repository, 'capable', wrapper)
def wrapper(orig, self, name, *args, **kwargs):
Peter Arrenbrecht
tests: support multiple caps in notcapable
r14409 if name in '$CAP'.split(' '):
Steven Brown
tests: add script to disable a selected wire protocol capability...
r14011 return False
return orig(self, name, *args, **kwargs)
EOF
echo '[extensions]' >> $HGRCPATH
echo "notcapable-$CAP = `pwd`/notcapable-$CAP.py" >> $HGRCPATH