kenkeiras / org-rw

A python library to parse, modify and save Org-mode files.
4 stars 0 forks source link

Easiest way to set the todo_keywords and done_keywords globally #2

Closed lyz-code closed 2 months ago

lyz-code commented 3 months ago

I've seen that org-rw reads the todo_keywords and done_keywords from the files when loading them. I'm going to load many files that don't have that property set as I configure it at nvim-orgmode configuration level.

I've also dived through the code to see how to pass my custom values to the load function but it does not seem trivial. Which way would you do that? If you give me a sketch on how you'd like it I wouldn't mind creating a PR.

Thaaanks

kenkeiras commented 2 months ago

Addressed on: https://code.codigoparallevar.com/kenkeiras/org-rw/pulls/4

See new examples: https://github.com/kenkeiras/org-rw/blob/40d58d54889a03691065ff2122b6c47ada53c0e0/tests/test_org.py#L836-L849

We might want to consider a more structured (and less stringified) approach to this. We can add an alternate type to that org-todo-keywords which takes an appropriate structure.

lyz-code commented 2 months ago

Thanks!