From a22129c343d9236277dcc0353c48cb53bc3417ce Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Tue, 29 Sep 2026 18:32:37 -0300 Subject: pardes --wait (-w) in a pane returns only once the pane its file landed in is deleted, so it can be $EDITOR A launch inside a pane forwards its file to the session's look and returned at once, so fish's Ctrl-O (edit_command_buffer), git commit and crontab -e read their still-unedited file back and went on. With --wait, as acme's E against B and read the way plan9port's E reads acme's log, it finds the pane /index names the file by (the one already showing it, if open), follows /log on one connection with 'follow new', reads /index once more to catch a Del that came first, and then blocks with no deadline until that pane's del record: exit 0, or 1 when the connection ends with the session. The 9P client's one-shot requests keep their 2 s deadline; its new follow takes it for the setup only. Outside pardes nothing changes. --help, docs/fs.md, the README and the 9P skill say to set EDITOR='pardes --wait', which GIT_EDITOR follows. Tested in fs.py (it returns within 50 ms of the Del, a second -w waits on the same pane, one whose session is killed exits 1) and end to end: fish 4.8 in a detached session, echo hi, Ctrl-O, the waiting launch idle in poll, the line edited over 9P, Save, Del, and fish ran echo edited. Co-Authored-By: Claude Opus 5.5 --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'README.md') diff --git a/README.md b/README.md index f60b0ed7..14803aef 100644 --- a/README.md +++ b/README.md @@ -36,6 +36,12 @@ serves the layout: `/layout` lists the columns, their places and panes, and `/tag` and `/col//tag` are the workspace and column tags, editable like a window's ([the tree](docs/fs.md#the-served-tree)). +`pardes FILE` in a pane opens FILE in that session and returns at once. As +`$EDITOR`, use `EDITOR='pardes --wait'` (`GIT_EDITOR` follows it): `--wait` +returns when that pane is deleted, so fish's Ctrl-O, `git commit` and +`crontab -e` read the file after you edit it +([forwarding](docs/fs.md#filesystem)). + plan9port's `9p write` always opens with OTRUNC, so `echo x | 9p write pardes//body` replaces the whole body where acme would append. To append, write through a mount with `>>` (`echo x >> $PARDES_MOUNT//body`). -- cgit v1.3