Fixed escape sequences
This commit is contained in:
parent
0593e9a4b6
commit
bb755b2773
7
main.py
7
main.py
@ -145,7 +145,7 @@ def main():
|
||||
),
|
||||
}
|
||||
|
||||
template.render(context)
|
||||
template.render(context, autoescape=True)
|
||||
|
||||
makedirs("output", exist_ok=True)
|
||||
template.save(Path("output", f"{lang}.docx"))
|
||||
@ -175,8 +175,5 @@ if __name__ == "__main__":
|
||||
)
|
||||
main()
|
||||
if args.convert_output:
|
||||
print(
|
||||
f"Converting everything to PDF...",
|
||||
flush=True,
|
||||
)
|
||||
print("Converting everything to PDF...", flush=True)
|
||||
convert(Path("output").absolute())
|
||||
|
@ -26,7 +26,7 @@ def data_read(key: str, *args: str, locale: str) -> Any:
|
||||
try:
|
||||
output = nested_read(key, *args, data=locale_file)
|
||||
except (KeyError, ValueError):
|
||||
default_file = locale_file = json_read(Path("data", f"default.json"))
|
||||
default_file = locale_file = json_read(Path("data", "default.json"))
|
||||
try:
|
||||
output = nested_read(key, *args, data=locale_file)
|
||||
except (KeyError, ValueError):
|
||||
|
Loading…
Reference in New Issue
Block a user