Mercurial > hg
diff hgext/transplant.py @ 20020:6fb59247c7d5
transplant: use peer of source repository as "remote" for "repo.pull()"
Before this patch, transplant with "--merge" option fails with
traceback unexpectedly, if it causes pull from the source repository
on the local host.
"discovery.findcommonincoming()" invokes "capable()" method on the
object given from "localrepository.pull()", but it is
"localrepository" object in this case and doesn't have such method.
This patch uses peer object of source repository as "remote" argument
for "localrepository.pull()" invocation like other invocations of it
in transplant.py.
author | FUJIWARA Katsunori <foozy@lares.dti.ne.jp> |
---|---|
date | Sat, 16 Nov 2013 23:14:20 +0900 |
parents | d51c4d85ec23 |
children | 27d3f1fe42ac |
line wrap: on
line diff
--- a/hgext/transplant.py Fri Nov 15 22:57:11 2013 -0500 +++ b/hgext/transplant.py Sat Nov 16 23:14:20 2013 +0900 @@ -154,7 +154,7 @@ # transplants before them fail. domerge = True if not hasnode(repo, node): - repo.pull(source, heads=[node]) + repo.pull(source.peer(), heads=[node]) skipmerge = False if parents[1] != revlog.nullid: