Roberto Togni26 downloadsMove completed tasks into a separate archive note, grouped by their original headings.
Todo2Done moves completed Markdown tasks from a source note into a separate archive note. It groups moved tasks under the same headings they had in the source, so the archive keeps their section structure.
Requires Obsidian 1.1.0 or later (uses
Vault.processfor safe read-modify-write).
By default, the source is TODO.md and the target is DONE.md. The source note must already exist. If the target note does not exist, the plugin creates it with a # Done heading.
The plugin recognizes task lines whose list marker is followed by a checked box, including - [x], * [X], and + [x]. Indentation before the list marker is allowed. Checkbox-looking text inside fenced code blocks is ignored.
A completed task moves only if it is part of a fully completed subtree: the task itself must be checked, every task nested under it must be checked, and every task it is nested under must be checked. In other words, checked children of unchecked parents stay put, and checked parents with unchecked children stay put too. This keeps partially finished work together instead of splitting it across two notes.
Cancelled tasks (- [-]) are treated as open, so they block their checked children from moving.
For each moved subtree, the plugin uses the root task's nearest preceding Markdown heading (# through ######) as its section. The source heading remains in place. In the target, tasks are added to a section with the same heading; if that section does not exist, it is appended. Tasks without a preceding heading go under ## Uncategorized.
Title underlined with === or ---) are not recognized as headings; tasks under them are routed as if no heading preceded them. Use ATX headings (# Title) in source notes.The source and target must be different notes. The plugin uses Vault.process for both writes, so a concurrent edit to either note aborts the move instead of overwriting it. If the target was updated but the source could not be, the plugin rolls the target back; if rollback also fails, it asks you to review both notes before retrying.
Install dependencies and start the development build:
npm install
npm run dev
Create a production build with:
npm run build
Run lint checks with:
npm run lint
Run tests with:
npm run test