[todoist2org] Add project name as file category

This commit is contained in:
Marcel Kapfer 2022-11-26 07:57:00 +01:00
parent c133b7068f
commit 877c6783fe
Signed by: mmk2410
GPG Key ID: CADE6F0C09F21B09
1 changed files with 2 additions and 0 deletions

View File

@ -146,10 +146,12 @@ def parse_project(project, parent_project_name=""):
if parent_project_name and project.parent_id:
content.append(f"#+title: {parent_project_name}: {project.name}")
content.append(f"#+category: {parent_project_name}: {project.name}")
parent_filename = get_filename(parent_project_name, False)
path = f"{output_dir}/{parent_filename}_{filename}"
else:
content.append(f"#+title: {project.name}")
content.append(f"#+category: {project.name}")
path = f"{output_dir}/{filename}"
if not project.parent_id: