summaryrefslogtreecommitdiff
path: root/docs/typ
diff options
context:
space:
mode:
Diffstat (limited to 'docs/typ')
-rw-r--r--docs/typ/cheatsheet.typ2
-rw-r--r--docs/typ/reference.typ49
-rw-r--r--docs/typ/themes.typ2
3 files changed, 51 insertions, 2 deletions
diff --git a/docs/typ/cheatsheet.typ b/docs/typ/cheatsheet.typ
index 5e373fac..e931effa 100644
--- a/docs/typ/cheatsheet.typ
+++ b/docs/typ/cheatsheet.typ
@@ -10,7 +10,7 @@
btn("B2"), [#word("Exec") the word or selection: a builtin, else a shell line.],
btn("B3"), [#word("Look"): open the file, address, directory or URL, else find the word's next place. Resting the pointer tints what #btn("B3") would take.],
[sweep], [drag #btn("B2") or #btn("B3") to #word("Exec") or #word("Look") exactly what you swept.],
- [grip], [drag the box left of a tag: up/down resizes, onto another column moves the pane. A column's right edge drags its width.],
+ [grip], [drag the box left of a tag: up/down resizes, onto another column moves the pane. A column's box: sideways resizes, past a neighbour's middle moves the column.],
)
=== Chords: hold the first, click the next
#pairs(
diff --git a/docs/typ/reference.typ b/docs/typ/reference.typ
index 7360179f..0d287381 100644
--- a/docs/typ/reference.typ
+++ b/docs/typ/reference.typ
@@ -38,6 +38,9 @@ addons the kinds of pane here, compiled in or an addon's @add
layout a line per column, then active <serial> @columns-and-tags
tag the workspace tag @columns-and-tags
tagexec a word clicked in the workspace tag @columns-and-tags
+plumb/ the plumber's: plumb(6) rules, and messages sent by them @plumber
+ rules the rules in force; a write adds rule sets, > replaces them @plumber
+ send write a message: six header lines, then its data @plumber
col/ the columns @columns-and-tags
<n>/ column <n>; rmdir closes it when empty @columns-and-tags
tag its tag
@@ -64,6 +67,7 @@ pane/ the panes @pa
look a #word("Look") at this pane @look-and-exec
exec an #word("Exec") at this pane @look-and-exec
tagexec a word clicked in this pane's tag @look-and-exec
+ rows a line a row: where it points, how it is coloured (README) @panes
pty/ terminals only @pty
ctl winsize, sig, exec @pty
status cols rows busy @pty
@@ -1015,6 +1019,51 @@ at 200, ending in `…`. Control characters become spaces.
synthetic. Linux v9fs's truncation `mtime` hint is accepted and dropped.
- #file("/src/") with `-Dembed-sources=true`.
+= The plumber <plumber>
+
+Plan 9's plumber(4), its language plumb(6)'s, in the session: rules
+match a message and say where it goes. A #word("Look") does not ask it
+yet (the #word("Plumb") rules do, #doc("reference", section: "from-acme")).
+
+- #file("/plumb/rules") reads the rules in force: rule sets of
+ `object<tab>verb<tab>arg` lines, each set ended by a blank line, a
+ variable's `name=value` where it was set, an `include`'s rules in its
+ place. A session starts with `include basic`, pardes's own
+ (`src/plumbing`): a URL to the `web` port, an existing directory or file
+ (at the place written after it) to `edit`. A write adds rule sets, each
+ read as its blank line comes, the rest at the close; `>` replaces them
+ all. One open writes at a time (`file in use`). Kept in a dump.
+- A rule set that does not read is refused at the write it is whole in,
+ `plumb/rules:<line>: <why>` in rules.c's words (`unknown verb isnt`,
+ `ruleset must have patterns and actions`), and the rules stay as they
+ were. `$1`-`$9` are refused: pardes's regular expressions
+ (#doc("reference", section: "regexp")) have no submatches; write `$0`
+ and several `matches`, as Pike's two patterns do. `include basic` is
+ `src/plumbing`; another name is the configuration directory's file, an
+ absolute one where it says.
+- #file("/plumb/send") takes a message, plumb(6)'s six lines (`src`,
+ `dst`, `wdir`, `type`, `attr`, the data's length) and then the data,
+ in one write or several. The write is answered once it has gone where
+ the first rule set whose patterns hold says, or refused in Plan 9's
+ words: `bad plumb message format`, `couldn't find destination for
+ message` (no rule set takes it and it names no port), `no start action
+ for plumb message`, `no port for "client" rule`.
+- The verbs are plumb(6)'s: `is`, `matches` (the whole text; with
+ `click=N` in `attr`, the run around rune N, and the data cut to it),
+ `isfile` and `isdir` (a name found as #word("Look") finds one: past the
+ place written after it, in `wdir`, then #word("Incl")'s directories;
+ `$file` and `$dir` are where), `set`, `add` and `delete` (`delete` of
+ an attribute not there fails, as plumber's code does), and the actions
+ `plumb to <port>`, `plumb start <words>` and `plumb client <words>`.
+- The ports pardes reads itself: `edit` (the data opened as a
+ #word("Look") opens it, at `addr=` when given), `web` (the host's
+ browser, a URL of at most 256 bytes) and each loaded kind by its name
+ (`image`, `pdf`). A message to another port runs its rule set's
+ `start` or `client`; to a port no rule names it goes nowhere.
+- `plumb start` runs its words as #word("Exec") runs a line: a builtin in
+ place at the pane with the keyboard, anything else a command pane in
+ the message's `wdir`, each word one argument to the shell.
+
= Addons <addons>
An addon is a shared library that brings one kind of pane: a picture, a
diff --git a/docs/typ/themes.typ b/docs/typ/themes.typ
index 97b42748..a78cf66c 100644
--- a/docs/typ/themes.typ
+++ b/docs/typ/themes.typ
@@ -109,7 +109,7 @@ take `null`, so older files stay valid:
[`tag_active_bg`, `tag_active_fg`], [the focused pane's tag; a ground closer than 1.25:1 to `tag_bg` is pushed further the way it leans, as far as its text keeps its contrast. Absent: `tag_bg`, `tag_fg`],
[`tagline_bg`, `tagline_fg`], [the tagline, the workspace row: an editor's status bar in its own colours (`dark_plus` has VS Code's blue). Absent: the tag's],
[`tag_name_fg`, `tag_active_name_fg`], [the file name's or a terminal's #word("Term") tint, in normal and focused tags. Absent: the tag's foreground],
- [`column_box`, `column_box_dim`], [a column's grip held (and its drag rail), and at rest. Absent: `num`; a mix of `column_box` and `tag_bg`],
+ [`column_box`, `column_box_dim`], [a column's grip held, and at rest. Absent: `num`; a mix of `column_box` and `tag_bg`],
[`border`], [quiet separators, lifted to 1.6:1 when under 1.5:1 off the page. Absent: `scroll_track`],
[`empty_col`], [a column with no pane, under its tag (acme: white). Absent: `border`],
[`lineno_active`], [the current line number. Absent: `lineno`],