##// END OF EJS Templates
templatespec: use new factory functions in logcmdutil...
Martin von Zweigbergk -
r45827:c1915cfa default
parent child Browse files
Show More
@@ -620,7 +620,7 b' def _lookuptemplate(ui, tmpl, style):'
620 if not tmpl and not style: # template are stronger than style
620 if not tmpl and not style: # template are stronger than style
621 tmpl = ui.config(b'ui', b'logtemplate')
621 tmpl = ui.config(b'ui', b'logtemplate')
622 if tmpl:
622 if tmpl:
623 return templatespec(templater.unquotestring(tmpl), None)
623 return formatter.literal_templatespec(templater.unquotestring(tmpl))
624 else:
624 else:
625 style = util.expandpath(ui.config(b'ui', b'style'))
625 style = util.expandpath(ui.config(b'ui', b'style'))
626
626
@@ -632,7 +632,7 b' def _lookuptemplate(ui, tmpl, style):'
632 ) or templater.templatepath(mapfile)
632 ) or templater.templatepath(mapfile)
633 if mapname:
633 if mapname:
634 mapfile = mapname
634 mapfile = mapname
635 return templatespec(None, mapfile)
635 return formatter.mapfile_templatespec(b'changeset', mapfile)
636
636
637 return formatter.lookuptemplate(ui, b'changeset', tmpl)
637 return formatter.lookuptemplate(ui, b'changeset', tmpl)
638
638
@@ -640,7 +640,7 b' def _lookuptemplate(ui, tmpl, style):'
640 def maketemplater(ui, repo, tmpl, buffered=False):
640 def maketemplater(ui, repo, tmpl, buffered=False):
641 """Create a changesettemplater from a literal template 'tmpl'
641 """Create a changesettemplater from a literal template 'tmpl'
642 byte-string."""
642 byte-string."""
643 spec = templatespec(tmpl, None)
643 spec = formatter.literal_templatespec(tmpl)
644 return changesettemplater(ui, repo, spec, buffered=buffered)
644 return changesettemplater(ui, repo, spec, buffered=buffered)
645
645
646
646
General Comments 0
You need to be logged in to leave comments. Login now