diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/Server/Plugins/Metadata.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/lib/Server/Plugins/Metadata.py b/src/lib/Server/Plugins/Metadata.py index d9c9c2a43..345f14b54 100644 --- a/src/lib/Server/Plugins/Metadata.py +++ b/src/lib/Server/Plugins/Metadata.py @@ -280,7 +280,8 @@ class Metadata(Bcfg2.Server.Plugin.MetadataPlugin, fd = datafile.fileno() while self.locked(fd) == True: pass - datafile.write(lxml.etree.tostring(self.clientdata_original.getroot())) + datafile.write(lxml.etree.tostring(self.clientdata_original.getroot(), + pretty_print='true')) fcntl.lockf(fd, fcntl.LOCK_UN) datafile.close() @@ -302,7 +303,8 @@ class Metadata(Bcfg2.Server.Plugin.MetadataPlugin, value=self.probedata[client][probe]) for group in self.cgroups[client]: lxml.etree.SubElement(cx, "Group", name=group) - data = lxml.etree.tostring(top, encoding='UTF-8', xml_declaration=True) + data = lxml.etree.tostring(top, encoding='UTF-8', xml_declaration=True, + pretty_print='true') try: datafile = open("%s/%s" % (self.data, 'probed.xml'), 'w') except IOError: |