Mercurial > public > mercurial-scm > hg
diff mercurial/commands.py @ 23507:67045b5a903a
graft: show hashes in user-facing messages
Graft was in various places just showing the revision number in status
messges. Instead, also show the stable and more useful short hash.
author | Mads Kiilerich <madski@unity3d.com> |
---|---|
date | Tue, 09 Dec 2014 03:38:23 +0100 |
parents | dc82f1a7436d |
children | 2164226a5637 |
line wrap: on
line diff
--- a/mercurial/commands.py Tue Dec 09 03:38:23 2014 +0100 +++ b/mercurial/commands.py Tue Dec 09 03:38:23 2014 +0100 @@ -3396,7 +3396,8 @@ # don't mutate while iterating, create a copy for rev in list(revs): if rev in ancestors: - ui.warn(_('skipping ancestor revision %s\n') % rev) + ui.warn(_('skipping ancestor revision %d:%s\n') % + (rev, repo[rev])) # XXX remove on list is slow revs.remove(rev) if not revs: @@ -3422,23 +3423,25 @@ except error.RepoLookupError: r = None if r in revs: - ui.warn(_('skipping revision %s (already grafted to %s)\n') - % (r, rev)) + ui.warn(_('skipping revision %d:%s ' + '(already grafted to %d:%s)\n') + % (r, repo[r], rev, ctx)) revs.remove(r) elif ids[n] in revs: if r is None: - ui.warn(_('skipping already grafted revision %s ' - '(%s also has unknown origin %s)\n') - % (ids[n], rev, n)) + ui.warn(_('skipping already grafted revision %d:%s ' + '(%d:%s also has unknown origin %s)\n') + % (ids[n], repo[ids[n]], rev, ctx, n[:12])) else: - ui.warn(_('skipping already grafted revision %s ' - '(%s also has origin %d)\n') - % (ids[n], rev, r)) + ui.warn(_('skipping already grafted revision %d:%s ' + '(%d:%s also has origin %d:%s)\n') + % (ids[n], repo[ids[n]], rev, ctx, r, n[:12])) revs.remove(ids[n]) elif ctx.hex() in ids: r = ids[ctx.hex()] - ui.warn(_('skipping already grafted revision %s ' - '(was grafted from %d)\n') % (r, rev)) + ui.warn(_('skipping already grafted revision %d:%s ' + '(was grafted from %d:%s)\n') % + (r, repo[r], rev, ctx)) revs.remove(r) if not revs: return -1