summaryrefslogtreecommitdiff
path: root/src/fs-help.txt
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-09-27 17:41:55 -0300
committerGabriel Schneider <[email protected]>2026-10-01 00:12:14 -0300
commit542dd489149e33915d19878a277e23b3a9c0b070 (patch)
treeaeb557581446621c366a2d3cd5888d25b37c5916 /src/fs-help.txt
parentc11ffe24f022d61cdd479e1ee946033c42e9a08c (diff)
downloadpardes-542dd489149e33915d19878a277e23b3a9c0b070.tar.gz
pardes-542dd489149e33915d19878a277e23b3a9c0b070.zip
Record /log whether or not anyone reads it, with the editor's messages in it
/log is now one ring (64 KiB, 4 KiB on the board) that records new, del, rename and save, and a msg line for everything the editor says. An open freezes it, so cat log shows what happened lately and ends; writing follow to that same open makes reads past it wait for newer records, and a follower the ring outran reads lost N first. The message log keeps the pane's serial, not its reusable slot. A test now fails when the tree serves a file /README never mentions; it caught pty/status, now documented along with typing through pty/data. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'src/fs-help.txt')
-rw-r--r--src/fs-help.txt9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/fs-help.txt b/src/fs-help.txt
index 7f55b3af..dca2c14e 100644
--- a/src/fs-help.txt
+++ b/src/fs-help.txt
@@ -5,7 +5,8 @@ index one line per pane: serial, kind (text|term|pdf|image), dirty flag, n
status pid, version and pane count
look write a line: a right click on it at the active pane; read: the serials it touched
exec write a line: a middle click, an editor command word or a shell line; read the same
-log one line per editor event (new/del/rename/save <serial> <name>); reads wait
+log recent events, one a line: new/del/rename/save <serial> <name>, and
+ msg <serial|-> <text> for what the editor said; write follow to wait
screen rendered screen as JSON, frozen from open to close
listeners the session's dial addresses
pane/new open it to make a pane; the read answers that pane's serial
@@ -26,9 +27,10 @@ Below, $m is the mount point (PARDES_MOUNT in a Tty9p shell; 9ns and 9p work too
echo '#0,#5' > $m/pane/$n/addr; printf NEW >> $m/pane/$n/data replace bytes 0..5
cp $m/pane/$n/addr $m/pane/$n/dot; cat $m/pane/$n/sel select the range, read it
cat $m/pane/$n/dirty; echo 0 > $m/pane/$n/dirty is it modified? say it is not
- cat $m/log block until a pane is made, renamed, saved or closed
+ exec 3<>$m/log; echo follow >&3; cat <&3 what happened lately, then wait for more
cat $m/pane/$n/event hold it open to own that pane's clicks
echo exec > $m/pane/$n/pty/ctl restart a shell; also winsize C R, sig INT
+ printf 'ls\r' > $m/pane/$n/pty/data type into a terminal; pty/status: cols rows busy
Pitfalls, one each:
Each open of pane/new makes another pane; two reads of one fid name the same one.
@@ -39,6 +41,5 @@ Pitfalls, one each:
Writing body appends; open it with truncation to replace; writes are whole UTF-8 sequences.
Truncating tag clears the part you may edit; truncating dot or addr empties it.
A terminal's body is a history snapshot frozen per open; pty/data is the live stream.
- screen is frozen per open handle as well; reopen it for a fresh frame.
- A failing command is reported in the editor, not as a write error; a bad line fails the write.
+ A failing command is reported in the editor and in log, not as a write error; a bad line fails the write.
pane/<n>/ctl reads acme's window status line and takes one verb, get, which reloads from disk.