From 97932c5bb268d0423caf95196dd75ea2afac84b0 Mon Sep 17 00:00:00 2001 From: Rijnder Wever Date: Thu, 5 Dec 2024 18:51:17 +0100 Subject: [PATCH] fix: use tabs instead of spaces for indentation I like spaces better, but this way, XML output matches MDTO's output byte-for-byte. --- mdto/mdto.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mdto/mdto.py b/mdto/mdto.py index b7bb5ac..99a4e96 100755 --- a/mdto/mdto.py +++ b/mdto/mdto.py @@ -733,7 +733,7 @@ def to_xml(self) -> ET.ElementTree: # can you abstract this? this is now double # on the other hand, formatting preferences should be handled by e.g. xmllint tree = ET.ElementTree(mdto) - ET.indent(tree, space=" ") # use 4 spaces as indentation + ET.indent(tree, space="\t") # use tabs as indentation (this matches what MDTO does) return tree @@ -829,7 +829,7 @@ def to_xml(self) -> ET.ElementTree: root.append(self.isRepresentatieVan.to_xml("isRepresentatieVan")) tree = ET.ElementTree(mdto) - ET.indent(tree, space=" ") # use 4 spaces as indentation + ET.indent(tree, space="\t") # use tabs as indentation (this matches what MDTO does) return tree