##// END OF EJS Templates
streamclone: refactor maybeperformstreamclone to take a pullop...
Gregory Szorc -
r26458:36279329 default
parent child Browse files
Show More
@@ -964,9 +964,7 b' def pull(repo, remote, heads=None, force'
964 lock = pullop.repo.lock()
964 lock = pullop.repo.lock()
965 try:
965 try:
966 pullop.trmanager = transactionmanager(repo, 'pull', remote.url())
966 pullop.trmanager = transactionmanager(repo, 'pull', remote.url())
967 streamclone.maybeperformstreamclone(pullop.repo, pullop.remote,
967 streamclone.maybeperformstreamclone(pullop)
968 pullop.heads,
969 pullop.streamclonerequested)
970 _pulldiscovery(pullop)
968 _pulldiscovery(pullop)
971 if _canusebundle2(pullop):
969 if _canusebundle2(pullop):
972 _pullbundle2(pullop)
970 _pullbundle2(pullop)
@@ -66,9 +66,14 b' def canperformstreamclone(repo, remote, '
66
66
67 return True, requirements
67 return True, requirements
68
68
69 def maybeperformstreamclone(repo, remote, heads, stream):
69 def maybeperformstreamclone(pullop):
70 supported, requirements = canperformstreamclone(repo, remote, heads,
70 repo = pullop.repo
71 streamrequested=stream)
71 remote = pullop.remote
72
73 r = canperformstreamclone(repo, remote, pullop.heads,
74 streamrequested=pullop.streamclonerequested)
75 supported, requirements = r
76
72 if not supported:
77 if not supported:
73 return
78 return
74
79
General Comments 0
You need to be logged in to leave comments. Login now