progress: add progress calls to changeset discovery
authorMatt Mackall <mpm@selenic.com>
Sat, 13 Feb 2010 00:38:29 -0600
changeset 10435 956498af9812
parent 10434 ad104a786d35
child 10437 8a99388f87cc
child 10459 c14530294269
progress: add progress calls to changeset discovery
mercurial/localrepo.py
--- a/mercurial/localrepo.py	Fri Feb 12 21:53:32 2010 -0600
+++ b/mercurial/localrepo.py	Sat Feb 13 00:38:29 2010 -0600
@@ -1342,6 +1342,7 @@
 
             if r:
                 reqcnt += 1
+                self.ui.progress('searching', reqcnt, unit='queries')
                 self.ui.debug("request %d: %s\n" %
                             (reqcnt, " ".join(map(short, r))))
                 for p in xrange(0, len(r), 10):
@@ -1354,6 +1355,7 @@
         while search:
             newsearch = []
             reqcnt += 1
+            self.ui.progress('searching', reqcnt, unit='queries')
             for n, l in zip(search, remote.between(search)):
                 l.append(n[1])
                 p = n[0]
@@ -1389,6 +1391,7 @@
         self.ui.debug("found new changesets starting at " +
                      " ".join([short(f) for f in fetch]) + "\n")
 
+        self.ui.progress('searching', None, unit='queries')
         self.ui.debug("%d total queries\n" % reqcnt)
 
         return base.keys(), list(fetch), heads