obsidian-tasks
obsidian-tasks copied to clipboard
Optional automatic action upon task completion: move task to an archive file
⚠️ Please check that this feature request hasn't been suggested before.
- [X] I searched previous Ideas in Discussions didn't find any similar feature requests.
- [X] I searched previous Issues didn't find any similar feature requests.
- [X] I am only requesting a single feature. Multiple changes should be split into individual requests, with links between them.
- [X] I believe my requested feature will be generally applicable to other users, not just me: it is not uniquely tied to my personal workflow.
🔖 Feature description
(Note: Similar functionality has been submitted in Issues and/or covered in Discussions previously.)
A new, optional task field should be supported by Tasks, to trigger the plugin to act upon a task when it is completed. One such action would entail automatically moving the task to the end of an archive file.
✔️ Solution
Support could be added for a new, optional task field or attribute. It could be called Finish
, and signified by a checkered flag emoji 🏁 (or [finish:: ]
in Dataview format). The '`Finish' field should be added to the plugin's Create/Edit Task modal dialog.
If the field value is set to_file
then, when the task is completed, Tasks will automatically delete it from note file that hosted it appears and then write it to the end of a dedicated archive file (Completed Tasks.md
in the vault's root directory, by default.)
For more flexibility, a new option could be added to Tasks' configuration settings: by default, it would display the default archive file path shown above; but it would allow the user to change the filename and/or location.
A possible later enhancement would support users' specifying a Finish to_file
heading within a note's YAML front matter that would override the vault-wide setting for completed tasks in that particular note.
In any event: if the designated archive file doesn't exist when a task containing 🏁 to_file
is completed, then the plugin will create it before writing the task to it.
❓ Alternatives
No other currently available plugin performs the desired action automatically when the task is completed.
📝 Additional Context
This issue is being created at the maintainer's direction.
If you want this functionality added to Tasks, please respond to this description with a thumbs up - 👍.