changeset 15631:e5fd140a4e69

annotate: show full changeset hash when invoked with --debug and -c
author Ion Savin <comp_@gmx.net>
date Fri, 09 Dec 2011 14:14:30 +0200
parents e6868bd17f24
children 4fbd0eeeb52c
files mercurial/commands.py
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/commands.py	Fri Dec 09 17:58:12 2011 +0100
+++ b/mercurial/commands.py	Fri Dec 09 14:14:30 2011 +0200
@@ -248,9 +248,11 @@
     if not pats:
         raise util.Abort(_('at least one filename or pattern is required'))
 
+    hexfn = ui.debugflag and hex or short
+
     opmap = [('user', ' ', lambda x: ui.shortuser(x[0].user())),
              ('number', ' ', lambda x: str(x[0].rev())),
-             ('changeset', ' ', lambda x: short(x[0].node())),
+             ('changeset', ' ', lambda x: hexfn(x[0].node())),
              ('date', ' ', getdate),
              ('file', ' ', lambda x: x[0].path()),
              ('line_number', ':', lambda x: str(x[1])),