Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 1.0, 1.0.1, and 1.0.2

csinfo: improve markups for 'rev' item

For patch file has only revision hash.

Changeset ed00cdebebf6

Parent f33fa7544993

by Yuki KODAMA

Changes to one file · Browse files at ed00cdebebf6 Showing diff from parent f33fa7544993 Diff from another changeset...

 
13
14
15
16
 
17
18
19
 
171
172
173
174
 
175
176
177
 
322
323
324
325
 
 
 
 
326
327
328
 
13
14
15
 
16
17
18
19
 
171
172
173
 
174
175
176
177
 
322
323
324
 
325
326
327
328
329
330
331
@@ -13,7 +13,7 @@
 import binascii    from mercurial import patch, util, error -from mercurial.node import short, hex +from mercurial.node import hex    from tortoisehg.util.i18n import _  from tortoisehg.util import hglib, paths @@ -171,7 +171,7 @@
  def __str__(self):   node = self.node()   if node: - return short(node) + return node[:12]   return ''     def __int__(self): @@ -322,7 +322,10 @@
  if item == 'rev':   revnum, revid = value   revid = gtklib.markup(revid, **mono) - return '%s (%s)' % (revnum, revid) + if revnum: + return '%s (%s)' % (revnum, revid) + else: + return '%s' % revid   elif item in ('revid', 'transplant'):   return gtklib.markup(value, **mono)   elif item == 'revnum':