diff options
| author | Gabriel Schneider <[email protected]> | 2026-11-01 15:50:00 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-11-01 15:57:25 -0300 |
| commit | d79c5de9dbf77c06fb2174782093051786be2153 (patch) | |
| tree | 8887d7e6dfea6023b9c7a05124eab56037198868 /docs/typ | |
| parent | 15bd47670102ceae36565ee299fd8a40625c3b21 (diff) | |
| download | pardes-d79c5de9dbf77c06fb2174782093051786be2153.tar.gz pardes-d79c5de9dbf77c06fb2174782093051786be2153.zip | |
fs: /sessions, the pardes daemon's registry in every session's tree, as pardes --ps lists it and a record a line, as the daemon says it (daemon <pid>; session <pid> tty|gui attached|detached <name>, a shell <pid> line for each shell it holds; orphan <pid>): a snapshot frozen at the open as /listeners is, its read the daemon's `list` asked out of the turn as a tape site (`sessions`), so a replica reads the authority's answer; none in a build with no daemon (web, esp32), and `no pardes daemon answers` with none running or one too old to list; README, the reference and Scripting's ls say it; test/daemon.py --manage reads it beside --ps
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'docs/typ')
| -rw-r--r-- | docs/typ/reference.typ | 11 | ||||
| -rw-r--r-- | docs/typ/scripting.typ | 2 |
2 files changed, 10 insertions, 3 deletions
diff --git a/docs/typ/reference.typ b/docs/typ/reference.typ index 4de57d64..e60964cc 100644 --- a/docs/typ/reference.typ +++ b/docs/typ/reference.typ @@ -26,6 +26,7 @@ pager write a directory: a new +Pager there; read: its serial @pardes log the event log; write follow to wait for more @log screen the rendered screen as JSON @on-screen listeners dial addresses @other-files +sessions the pardes daemon's sessions and shells (pardes --ps) @other-files focus the serial of the pane with the keyboard; write one to move it @columns-and-tags ctl settings and session builtins @root-ctl commands every builtin, one a line @other-files @@ -157,7 +158,7 @@ other clients about, write and read on one open: #cmd("exec 3<>$m/pane/$n/look; echo x >&3; cat <&3; exec 3<&-") *Snapshots.* #file("/index"), #file("/layout"), #file("/recent"), -#file("/commands"), #file("/status"), #file("/listeners"), a read-only +#file("/commands"), #file("/status"), #file("/listeners"), #file("/sessions"), a read-only #file("ctl"), #file("/log"), #file("/screen") and a terminal's #file("body") freeze at the open, so one read in several chunks never splices two moments; open again for now. @@ -188,7 +189,7 @@ the range and flag files, the workspace's #file("tag"), the root #file("look")/#file("exec") answers, #file("focus"); #file("event") and #file("pty/data") the next record's, zero when none waits. A stream and a view generated by each read stat 0, as acme's do: #file("log"), #file("screen"), #file("data"), #file("xdata"), #file("index"), -#file("layout"), #file("recent"), #file("listeners"), #file("pane/new"). +#file("layout"), #file("recent"), #file("listeners"), #file("sessions"), #file("pane/new"). Read those to the end rather than trust a length (`cat` does). The qid version of #file("body"), #file("data") and #file("xdata") is the pane's revision, so a stat sees an edit land. Modes are 0644/0666, 0444 @@ -930,6 +931,12 @@ at 200, ending in `…`. Control characters become spaces. `+Pager` of the session's. - #file("/listeners"): the session's dial addresses, a line each (#doc("building", section: "listeners")). +- #file("/sessions"): what the pardes daemon keeps, as `pardes --ps` + shows it, a record a line: `daemon <pid>`, then `session <pid> tty|gui + attached|detached <name>` with a `shell <pid>` line for each shell it + holds, then `orphan <pid>` for each shell no session holds. Any of the + names attaches (`pardes --attach=<name>`, either kind). Read fails `no + pardes daemon answers` with none, or one too old to list (Upgrade it). - #file("/os/"): existing regular files take read, write and truncation to zero; create, remove, rename and mode changes are refused as not permitted (`permission denied`, EACCES through a mount); ownership is diff --git a/docs/typ/scripting.typ b/docs/typ/scripting.typ index 590d71ac..d90f68ac 100644 --- a/docs/typ/scripting.typ +++ b/docs/typ/scripting.typ @@ -10,7 +10,7 @@ files is an extension: ``` $ ls $m README col commands ctl exec focus index layout listeners log -look os pager pane recent screen status tag tagexec +look os pager pane recent screen sessions status tag tagexec $ cat $m/index 1 term 0 /home/me/src 1 2 text 0 /home/me/src/+New 1 |
