notes-export
Installation
SKILL.md
notes-export — full local snapshot of Apple Notes
Self-Evolving skill — if export behavior drifts (AE size caps, chunk failures, encoding), fix this SKILL.md and
scripts/notes.tsOSA_EXPORT(+ a test innotes-core.test.tsfor any pure helper change); see the Post-Execution Reflection at the bottom.
One command captures everything Notes holds into a timestamped local snapshot:
NC="$HOME/.claude/plugins/marketplaces/cc-skills/plugins/notes-commander/scripts/notes.ts"
bun "$NC" export # → ~/.local/share/notes-commander/export/<stamp>/
bun "$NC" export --out /path/to/dir # explicit destination
What a snapshot contains:
- One markdown file per note, under
<account>/<folder>/…mirroring the Notes hierarchy. Each file has YAML frontmatter (account,folder,id,modified) and the note body as plain text (decoded viatextutil, UTF-8-safe, CJK-safe). manifest.json— every folder (with counts) and every note (id, name, modified, relative file path, char count). This is the machine-readable index for audits and diffs.- Filenames are sanitized (
safeFilename) and suffixed with the note's core-data id (.p1234.md), so same-titled notes never collide.