##// END OF EJS Templates
drop {short,hex}(ctx.node()) calls in favor of ctx methods
Alexander Solovyov -
r14055:421d56a0 default
parent child Browse files
Show More
@@ -351,13 +351,12 b' def bisect(ui, repo, rev=None, extra=Non'
351 else:
351 else:
352 ui.write(_("The first bad revision is:\n"))
352 ui.write(_("The first bad revision is:\n"))
353 displayer.show(repo[nodes[0]])
353 displayer.show(repo[nodes[0]])
354 parents = repo[nodes[0]].parents()
355 extendnode = extendbisectrange(nodes, good)
354 extendnode = extendbisectrange(nodes, good)
356 if extendnode is not None:
355 if extendnode is not None:
357 ui.write(_('Not all ancestors of this changeset have been'
356 ui.write(_('Not all ancestors of this changeset have been'
358 ' checked.\nUse bisect --extend to continue the '
357 ' checked.\nUse bisect --extend to continue the '
359 'bisection from\nthe common ancestor, %s.\n')
358 'bisection from\nthe common ancestor, %s.\n')
360 % short(extendnode.node()))
359 % extendnode)
361 else:
360 else:
362 # multiple possible revisions
361 # multiple possible revisions
363 if good:
362 if good:
@@ -459,7 +458,7 b' def bisect(ui, repo, rev=None, extra=Non'
459 extendnode = extendbisectrange(nodes, good)
458 extendnode = extendbisectrange(nodes, good)
460 if extendnode is not None:
459 if extendnode is not None:
461 ui.write(_("Extending search to changeset %d:%s\n"
460 ui.write(_("Extending search to changeset %d:%s\n"
462 % (extendnode.rev(), short(extendnode.node()))))
461 % (extendnode.rev(), extendnode)))
463 if noupdate:
462 if noupdate:
464 return
463 return
465 cmdutil.bail_if_changed(repo)
464 cmdutil.bail_if_changed(repo)
@@ -80,7 +80,7 b' def _filerevision(web, tmpl, fctx):'
80 path=webutil.up(f),
80 path=webutil.up(f),
81 text=lines(),
81 text=lines(),
82 rev=fctx.rev(),
82 rev=fctx.rev(),
83 node=hex(fctx.node()),
83 node=fctx.hex(),
84 author=fctx.user(),
84 author=fctx.user(),
85 date=fctx.date(),
85 date=fctx.date(),
86 desc=fctx.description(),
86 desc=fctx.description(),
@@ -239,7 +239,7 b' def changelog(web, req, tmpl, shortlog=F'
239 changenav = webutil.revnavgen(pos, revcount, count, web.repo.changectx)
239 changenav = webutil.revnavgen(pos, revcount, count, web.repo.changectx)
240
240
241 return tmpl(shortlog and 'shortlog' or 'changelog', changenav=changenav,
241 return tmpl(shortlog and 'shortlog' or 'changelog', changenav=changenav,
242 node=hex(ctx.node()), rev=pos, changesets=count,
242 node=ctx.hex(), rev=pos, changesets=count,
243 entries=lambda **x: changelist(limit=0,**x),
243 entries=lambda **x: changelist(limit=0,**x),
244 latestentry=lambda **x: changelist(limit=1,**x),
244 latestentry=lambda **x: changelist(limit=1,**x),
245 archives=web.archivelist("tip"), revcount=revcount,
245 archives=web.archivelist("tip"), revcount=revcount,
@@ -582,7 +582,7 b' def annotate(web, req, tmpl):'
582 last = fnode
582 last = fnode
583
583
584 yield {"parity": parity.next(),
584 yield {"parity": parity.next(),
585 "node": hex(f.node()),
585 "node": f.hex(),
586 "rev": f.rev(),
586 "rev": f.rev(),
587 "author": f.user(),
587 "author": f.user(),
588 "desc": f.description(),
588 "desc": f.description(),
@@ -598,7 +598,7 b' def annotate(web, req, tmpl):'
598 annotate=annotate,
598 annotate=annotate,
599 path=webutil.up(f),
599 path=webutil.up(f),
600 rev=fctx.rev(),
600 rev=fctx.rev(),
601 node=hex(fctx.node()),
601 node=fctx.hex(),
602 author=fctx.user(),
602 author=fctx.user(),
603 date=fctx.date(),
603 date=fctx.date(),
604 desc=fctx.description(),
604 desc=fctx.description(),
@@ -655,7 +655,7 b' def filelog(web, req, tmpl):'
655 l.insert(0, {"parity": parity.next(),
655 l.insert(0, {"parity": parity.next(),
656 "filerev": i,
656 "filerev": i,
657 "file": f,
657 "file": f,
658 "node": hex(iterfctx.node()),
658 "node": iterfctx.hex(),
659 "author": iterfctx.user(),
659 "author": iterfctx.user(),
660 "date": iterfctx.date(),
660 "date": iterfctx.date(),
661 "rename": webutil.renamelink(iterfctx),
661 "rename": webutil.renamelink(iterfctx),
@@ -677,7 +677,7 b' def filelog(web, req, tmpl):'
677
677
678 nodefunc = lambda x: fctx.filectx(fileid=x)
678 nodefunc = lambda x: fctx.filectx(fileid=x)
679 nav = webutil.revnavgen(end - 1, revcount, count, nodefunc)
679 nav = webutil.revnavgen(end - 1, revcount, count, nodefunc)
680 return tmpl("filelog", file=f, node=hex(fctx.node()), nav=nav,
680 return tmpl("filelog", file=f, node=fctx.hex(), nav=nav,
681 entries=lambda **x: entries(limit=0, **x),
681 entries=lambda **x: entries(limit=0, **x),
682 latestentry=lambda **x: entries(limit=1, **x),
682 latestentry=lambda **x: entries(limit=1, **x),
683 revcount=revcount, morevars=morevars, lessvars=lessvars)
683 revcount=revcount, morevars=morevars, lessvars=lessvars)
@@ -762,7 +762,7 b' def graph(web, req, tmpl):'
762 for (id, type, ctx, vtx, edges) in tree:
762 for (id, type, ctx, vtx, edges) in tree:
763 if type != graphmod.CHANGESET:
763 if type != graphmod.CHANGESET:
764 continue
764 continue
765 node = short(ctx.node())
765 node = str(ctx)
766 age = templatefilters.age(ctx.date())
766 age = templatefilters.age(ctx.date())
767 desc = templatefilters.firstline(ctx.description())
767 desc = templatefilters.firstline(ctx.description())
768 desc = cgi.escape(templatefilters.nonempty(desc))
768 desc = cgi.escape(templatefilters.nonempty(desc))
@@ -790,8 +790,6 b' def help(web, req, tmpl):'
790
790
791 topicname = req.form.get('node', [None])[0]
791 topicname = req.form.get('node', [None])[0]
792 if not topicname:
792 if not topicname:
793 topic = []
794
795 def topics(**map):
793 def topics(**map):
796 for entries, summary, _ in helpmod.helptable:
794 for entries, summary, _ in helpmod.helptable:
797 entries = sorted(entries, key=len)
795 entries = sorted(entries, key=len)
@@ -66,7 +66,7 b' def _siblings(siblings=[], hiderev=None)'
66 if len(siblings) == 1 and siblings[0].rev() == hiderev:
66 if len(siblings) == 1 and siblings[0].rev() == hiderev:
67 return
67 return
68 for s in siblings:
68 for s in siblings:
69 d = {'node': hex(s.node()), 'rev': s.rev()}
69 d = {'node': s.hex(), 'rev': s.rev()}
70 d['user'] = s.user()
70 d['user'] = s.user()
71 d['date'] = s.date()
71 d['date'] = s.date()
72 d['description'] = s.description()
72 d['description'] = s.description()
General Comments 0
You need to be logged in to leave comments. Login now