##// END OF EJS Templates
log: use new namespaces api to display names...
Sean Farley -
r23772:07309e52 default
parent child Browse files
Show More
@@ -902,20 +902,26 b' class changeset_printer(object):'
902 self.ui.write(_("changeset: %d:%s\n") % (rev, hexfunc(changenode)),
902 self.ui.write(_("changeset: %d:%s\n") % (rev, hexfunc(changenode)),
903 label='log.changeset changeset.%s' % ctx.phasestr())
903 label='log.changeset changeset.%s' % ctx.phasestr())
904
904
905 # branches are shown first before any other names due to backwards
906 # compatibility
905 branch = ctx.branch()
907 branch = ctx.branch()
906 # don't show the default branch name
908 # don't show the default branch name
907 if branch != 'default':
909 if branch != 'default':
908 # i18n: column positioning for "hg log"
910 # i18n: column positioning for "hg log"
909 self.ui.write(_("branch: %s\n") % branch,
911 self.ui.write(_("branch: %s\n") % branch,
910 label='log.branch')
912 label='log.branch')
911 for bookmark in self.repo.nodebookmarks(changenode):
913
912 # i18n: column positioning for "hg log"
914 for name, ns in self.repo.names.iteritems():
913 self.ui.write(_("bookmark: %s\n") % bookmark,
915 # branches has special logic already handled above, so here we just
914 label='log.bookmark')
916 # skip it
915 for tag in self.repo.nodetags(changenode):
917 if name == 'branches':
916 # i18n: column positioning for "hg log"
918 continue
917 self.ui.write(_("tag: %s\n") % tag,
919 # we will use the templatename as the color name since those two
918 label='log.tag')
920 # should be the same
921 for name in ns.names(self.repo, changenode):
922 # i18n: column positioning for "hg log"
923 tname = _(("%s:" % ns.templatename).ljust(13) + "%s\n") % name
924 self.ui.write("%s" % tname, label='log.%s' % ns.templatename)
919 if self.ui.debugflag:
925 if self.ui.debugflag:
920 # i18n: column positioning for "hg log"
926 # i18n: column positioning for "hg log"
921 self.ui.write(_("phase: %s\n") % _(ctx.phasestr()),
927 self.ui.write(_("phase: %s\n") % _(ctx.phasestr()),
General Comments 0
You need to be logged in to leave comments. Login now