diff tests/test-evolve-obshistory.t @ 4917:d1d8e97d32af

obslog: make changeset available to templater obslog templating currently has very limited support for templating the precursor changeset (when available). The only available keywords are {node}, {rev}, and {shortdescription}. This patch makes the entire changeset available to the templater by passing it to formatter.context(). That function has been available since Mercurial 4.2.
author Martin von Zweigbergk <martinvonz@google.com>
date Mon, 04 Nov 2019 14:31:08 -0800
parents ab3581bc0637
children 6d40e0166522
line wrap: on
line diff
--- a/tests/test-evolve-obshistory.t	Wed Oct 16 11:10:04 2019 -0700
+++ b/tests/test-evolve-obshistory.t	Mon Nov 04 14:31:08 2019 -0800
@@ -168,3 +168,12 @@
        [evolve.verb|rewritten](description) as [evolve.node|fdf9bde5129a] using [evolve.operation|amend] by [evolve.user|test] [evolve.date|(Thu Jan 01 00:00:00 1970 +0000)]
          (No patch available, successor is unknown locally)
   
+
+  $ hg obslog 7a230b46bf61 --graph \
+  > -T '{node} {rev} {desc|firstline}\n{markers % "rewritten using {operation}"}\n'
+  o  7a230b46bf61 2 A2
+  |
+  x  fdf9bde5129a
+  |  rewritten using amend
+  @  471f378eab4c 1 A0
+     rewritten using amend