Export to Markdown or text, and import text as nodes (stage 9c)

:export md writes the document as Markdown headings in the clipboard's
format (the user's pick): # for the root and each loose node, ## for
their children, down to ######, the tags between --- lines, then the
body. :export txt writes an indented outline, tags after each title and
the body under it after "| " (the user's pick), from the new
storage::plain_text. The file goes next to the document, named after it,
or where it's told; as vim's :w to another file does, an existing file
needs :export! (the user's pick). Typed in visual mode, :export writes
just the selection, named after its first branch (the user's pick).

:import file reads Markdown headings, a list or indented lines with the
clipboard's reader, now also taking #tags at the end of a line and "| "
body lines, so a text export reads back whole. The nodes go under the
cursor's node, laid out as a mind map, as one undo step (the user's
pick).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
skkeyeandClaude Opus 5.5 committed 2026-10-02 11:46:04 -04:00
1 parent 5888d143fd
commit 9d15a054f2
14 files changed
+407 -33

No files matched your search

+2
View File
@@ -103,6 +103,8 @@ The plan for the everyday keys (all of them are in DESIGN.md):
| `gt` `gT` | the next / previous document |
| `:` `?` | command line, help (search it with `/`, Enter runs the key or command) |
| `:e` `:new` `:bd` | open a document / make one / close it |
| `:export md` `:export txt` | the document (or, from visual mode, the selection) as Markdown or an outline (`:export!` writes over a file) |
| `:import file` | the nodes in a Markdown or text file, under this node |
| `:marks` `:jumps` `:registers` | what they hold: Enter goes there (or pastes) |
| `:w` `:q` `ZZ` | save / close the pane (the last one quits) / save and close |