notetaker icon indicating copy to clipboard operation
notetaker copied to clipboard

Sync all todos with a file

Open hkdobrev opened this issue 5 years ago • 2 comments

Currently, exporting todos from all to a markdown file is as easy as:

notes todos > todos.md

It will group them based on the files they were found in.

However, there are few considerations:

  • It is useful to export all of your current todos in the same notes folder. This helps if you want to commit them in version control so you can have a single list of todos on mobile after pushing to GitHub.
  • When exporting to your notes folder, then future runs of notes todos would give you duplicate todos. You'd need to always put notes in folders and filter by them.
  • It'd be better if we have a notes todos --export flag which exports to a specific file like $NOTES_PATH/todos.md and then this file is excluded when running notes todos.
  • This would help with future syncing. E.g. notes todos --sync could sync todos from $NOTES_PATH/todos.md back to every individual file it came from. This would be really nice to run after checking off todos from the common list. E.g. checking off on GitHub or from your mobile and then syncing back on your computer.
  • Even better would be to run notes todos --sync in automatic action when changing $NOTES_PATH/todos.md. Could use run-if-changed locally in a git hook or even GitHub Action in your private notes repo so it works when checking checklist items from github.com.

Checklist:

  • [x] notes todos --export
  • [ ] notes todos --sync
  • [ ] Git hook for exporting/syncing
  • [ ] GitHub action for exporting/syncing

hkdobrev avatar May 11 '20 22:05 hkdobrev

notes todos --export is now implemented in #4.

hkdobrev avatar May 11 '20 23:05 hkdobrev

It would be interesting to consider the use case of ordering todos from all of your notes in priority order in todos.md when they are all in one place. How do you do that if notes todos --export is meant to always overwrite this "summary" todos file from your current notes?

hkdobrev avatar May 11 '20 23:05 hkdobrev