obsolete: export pretty printed json
authorPierre-Yves David <pierre-yves.david@logilab.fr>
Wed, 09 May 2012 12:43:45 +0200
changeset 226 0892b91947ef
parent 225 72af5aa43997
child 227 abe52cf492ee
obsolete: export pretty printed json Will help unavoidable hand fixing.
hgext/obsolete.py
--- a/hgext/obsolete.py	Tue May 08 19:52:50 2012 +0200
+++ b/hgext/obsolete.py	Wed May 09 12:43:45 2012 +0200
@@ -586,7 +586,7 @@
             jmark['subjects'] = [hex(n) for n in jmark['subjects']]
             jmark['object'] = hex(jmark['object'])
             markers.append(jmark)
-        json.dump(markers, stream)
+        json.dump(markers, stream, indent=4)
 
     def load(self, stream):
         for mark in json.load(stream):