Indent @-directives and set them upercase

This commit is contained in:
Matthias Krack 2024-01-16 15:09:04 +01:00
parent 233cc04966
commit f76adaefd7
224 changed files with 1372 additions and 1370 deletions

View file

@ -32,7 +32,7 @@ def format_line(line: str) -> str:
def indent(lines: List[str]) -> List[str]:
output = []
for line in lines:
output.append(f" {line}" if not line.startswith("@") else line)
output.append(f" {line}")
return output
@ -91,7 +91,9 @@ class Preprocessor(Child):
self.sortkey = "" # Pre-processor lines are not sortable.
def render(self, verbatim: bool) -> List[str]:
return self.preamble + [self.line]
tokens = self.line.split(" ", 1)
tokens[0] = tokens[0].upper()
return self.preamble + [" ".join(tokens)]
# ======================================================================================