obslog: add initial support for showing note in obslog
authorPulkit Goyal <7895pulkit@gmail.com>
Sun, 12 Nov 2017 01:35:51 +0530
changeset 3214 9fe2b3fd7fc7
parent 3213 7bc587557e4f
child 3215 175b524b9a2b
obslog: add initial support for showing note in obslog This add a very basic and initial support for showing the note stored in the obsmarker in obslog to test the upcoming changes which adds support. The UI is not finalised and will be improved in the patches after support is added and we have tests with the current output.
hgext3rd/evolve/obshistory.py
--- a/hgext3rd/evolve/obshistory.py	Sun Nov 12 01:26:30 2017 +0530
+++ b/hgext3rd/evolve/obshistory.py	Sun Nov 12 01:35:51 2017 +0530
@@ -499,6 +499,11 @@
     fm.write('date', '(%s)', fm.formatdate(date),
              label="evolve.date")
 
+    # initial support for showing note
+    if metadata.get('note'):
+        fm.plain('\n    note: ')
+        fm.write('note', "'%s'", metadata['note'], label="evolve.note")
+
     # Patch display
     if opts.get('patch'):
         _patchavailable = patchavailable(node, repo, marker)