Mercurial > hg-stable
changeset 11729:c91b86a291b0
rebase/progress: Adding progress for rebasing
author | timeless <timeless@gmail.com> |
---|---|
date | Tue, 20 Jul 2010 20:53:48 +0200 |
parents | 226a328a7ff3 |
children | 7469ff872122 |
files | hgext/rebase.py |
diffstat | 1 files changed, 7 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/rebase.py Thu Jul 22 18:47:46 2010 +0300 +++ b/hgext/rebase.py Tue Jul 20 20:53:48 2010 +0200 @@ -148,9 +148,13 @@ targetancestors = set(repo.changelog.ancestors(target)) targetancestors.add(target) - for rev in sorted(state): + sortedstate = sorted(state) + total = len(sortedstate) + pos = 0 + for rev in sortedstate: + pos += 1 if state[rev] == -1: - ui.debug("rebasing %d:%s\n" % (rev, repo[rev])) + ui.progress(_("rebasing"), pos, ("%d:%s" % (rev, repo[rev])), _(' changesets'), total) storestatus(repo, originalwd, target, state, collapsef, keepf, keepbranchesf, external) p1, p2 = defineparents(repo, rev, target, state, @@ -179,6 +183,7 @@ skipped.add(rev) state[rev] = p1 + ui.progress(_('rebasing'), None) ui.note(_('rebase merging completed\n')) if collapsef and not keepopen: