HTML output tweaks

This commit is contained in:
2025-10-18 10:38:43 -04:00
parent 171c5df068
commit 31455f075e
3 changed files with 91 additions and 8 deletions

View File

@ -162,6 +162,12 @@ def main():
loader=FileSystemLoader(os.path.dirname(__file__)),
autoescape=select_autoescape(['html', 'xml'])
)
# Add markdown filter
try:
import markdown
env.filters['markdown'] = lambda text: markdown.markdown(text or "")
except ImportError:
env.filters['markdown'] = lambda text: text or ""
template = env.get_template("todoist_backup_template.html")
html_filename = f"Todoist-Actual-Backup-{today}.html"
with open(html_filename, "w", encoding="utf-8") as f: