on master help sign in
Merge pull request #1091 from tinnus-napbus/update-dill-docs

update dill docs

commite8c681842d46740750fbe193289b958fb616abf2 authorpoprox <51337059+drbeefsupreme@users.noreply.github.com> dateWed 15 Sep 2021, 09:22 (5 years ago) parent73e5deb28cd310
6 files changed+625−384
content/docs/arvo/dill/_index.md+16 content/docs/arvo/dill/data-types.md+187 content/docs/arvo/dill/dill-api.md−366 content/docs/arvo/dill/dill.md+35−18 content/docs/arvo/dill/scry.md+45 content/docs/arvo/dill/tasks.md+342
content/docs/arvo/dill/_index.md+16
@@ -5,3 +5,19 @@ sort_by = "weight"
55template = "sections/docs/chapters.html"
66insert_anchor_links = "right"
77+++
8+
9+[Overview](/docs/avro/dill/dill)
10+
11+A brief overview of the Dill vane.
12+
13+[API Reference](/docs/arvo/dill/tasks)
14+
15+The `task`s Dill takes and the `gift`s it returns.
16+
17+[Scry Reference](/docs/arvo/dill/scry)
18+
19+The scry endpoints of Dill.
20+
21+[Data Types](/docs/arvo/dill/data-types)
22+
23+Reference documentation of the data types used by Dill.
content/docs/arvo/dill/data-types.mdnew file+187
@@ -0,0 +1,187 @@
1++++
2+title = "Data Types"
3+weight = 4
4+template = "doc.html"
5++++
6+
7+Here are the data types used by Dill, as defined in `/sys/lull.hoon`.
8+
9+## `$blew`
10+
11+```hoon
12+ +$ blew [p=@ud q=@ud]
13+```
14+
15+Terminal dimension; `p` is columns, `q` is rows. This structure is passed to Dill by the runtime in a [%blew](/docs/arvo/dill/tasks#blew) `task` whenever the dimensions of the terminal changes.
16+
17+## `$belt`
18+
19+```hoon
20++$ belt
21+ $? bolt
22+ $% [%mod mod=?(%ctl %met %hyp) key=bolt]
23+ [%txt p=(list @c)]
24+ [%ctl p=@c]
25+ [%met p=@c]
26+ == ==
27+```
28+
29+Terminal client input.
30+
31+A `$belt` is passed to Dill in a [%belt](/docs/arvo/dill/tasks#belt) `task` by the runtime whenever there is input, such as a user typing in the console. This is only used between the terminal client and Dill, a [$dill-belt](#dill-belt) is used between Dill and Arvo.
32+
33+May either be a [$bolt](#bolt) or one of:
34+
35+- `%mod` - Modifier (Ctrl, Meta or Hyper) plus [key].
36+- `%txt` - A series of characters
37+- `%ctl` - Ctrl+[key], deprecated in favour of `%mod`.
38+- `%met` - Meta+[key], deprecated in favour of `%mod`.
39+
40+## `$bolt`
41+
42+```hoon
43++$ bolt
44+ $@ @c
45+ $% [%aro p=?(%d %l %r %u)]
46+ [%bac ~]
47+ [%del ~]
48+ [%hit r=@ud c=@ud]
49+ [%ret ~]
50+ ==
51+```
52+
53+Simple input.
54+
55+Either a single simple character or one of:
56+
57+- `%aro` - Arrow keys.
58+- `%bac` - Backspace key.
59+- `%del` - Delete key.
60+- `%hit` - Mouse click - `r` is row and `c` is column. Note these are zero-indexed, with `[0 0]` being the _bottom left_ corner.
61+- `%ret` - Return (Enter) key.
62+
63+## `$blit`
64+
65+```hoon
66++$ blit
67+ $% [%bel ~]
68+ [%clr ~]
69+ [%hop p=@ud]
70+ [%klr p=stub]
71+ [%lin p=(list @c)]
72+ [%mor ~]
73+ [%sag p=path q=*]
74+ [%sav p=path q=@]
75+ [%url p=@t]
76+ ==
77+```
78+
79+Terminal client output.
80+
81+A `$blit` is given to the terminal client by Dill in a `%blit` `gift` when it wants to print some text, clear the screen, go _ding_ or what have you.
82+
83+This is only used between Dill and the terminal client, a [$dill-blit](#dill-blit) is used instead between Arvo and Dill.
84+
85+A `$blit` is one of:
86+
87+- `%bel` - Ring the terminal bell.
88+- `%clr` - Clear the screen.
89+- `%hop` - Set cursor position, `p` specifies its position on the prompt line.
90+- `%klr` - Set styled line, the `$stub` specifies the text and style.
91+- `%lin` - Set current line, `p` contains the text.
92+- `%mor` - Newline.
93+- `%sag` - Save to jamfile, typically in `/[pier]/.urb/put/`. `p` is `/[path]/[filename]/[extension]`. For example, `/foo/bar` will save it in `/[pier]/.urb/put/foo.bar`, `/a/b/c/foo/bar` will save it in `/[pier]/.urb/put/a/b/c/foo.bar`, and `/foo` will save it in `/[pier]/.urb/put.foo`. `q` is the `noun` to `jam` and save in the file.
94+- `%sav` - Save to file. Same behaviour as `%sag` except `q` is an `atom` rather than a `noun` and therefore doesn't need to be `jam`med. The `atom` is written to disk as if it were the bytestring in the tail of an `$octs`. That is, `%sav`ing the `cord` `'abcdef'`, whose `@ux` value is `0x6665.6463.6261`, results in a unix file whose hex dump renders as `61 62 63 64 65 66`.
95+- `%url` - Activate URL, `p` is the URL.
96+
97+## `$dill-belt`
98+
99+```hoon
100++$ dill-belt
101+ $% [%aro p=?(%d %l %r %u)]
102+ [%bac ~]
103+ [%cru p=@tas q=(list tank)]
104+ [%ctl p=@]
105+ [%del ~]
106+ [%hey ~]
107+ [%met p=@]
108+ [%ret ~]
109+ [%rez p=@ud q=@ud]
110+ [%txt p=(list @c)]
111+ [%yow p=gill:gall]
112+ ==
113+```
114+
115+Terminal input for Arvo.
116+
117+While [$belt](#belt) is used between the terminal client and Dill, `$dill-belt` is used between Dill and Arvo.
118+
119+a `$dill-belt` is one of:
120+
121+- `%aro` - Arrow keys.
122+- `%bac` - Backspace key.
123+- `%cru` - Echo error, `p` is an error `@tas` and `q` is a traceback.
124+- `%ctl` - Ctrl+[key].
125+- `%del` - Delete key.
126+- `%hey` - Refresh.
127+- `%met` - Meta+[key].
128+- `%ret` - Return key (Enter).
129+- `%rez` - Terminal resized, `p` is columns and `q` is rows.
130+- `%txt` - Text input.
131+- `%yow` - Connect to app.
132+
133+## `$dill-blit`
134+
135+```hoon
136++$ dill-blit
137+ $% [%bel ~]
138+ [%clr ~]
139+ [%hop p=@ud]
140+ [%klr p=stub]
141+ [%mor p=(list dill-blit)]
142+ [%pom p=stub]
143+ [%pro p=(list @c)]
144+ [%qit ~]
145+ [%out p=(list @c)]
146+ [%sag p=path q=*]
147+ [%sav p=path q=@]
148+ [%url p=@t]
149+ ==
150+```
151+
152+Terminal output from Arvo.
153+
154+While [$blit](#blit) is used between Dill and the terminal client, `$dill-blit` is used between Arvo and Dill.
155+
156+A `$dill-blit` is one of:
157+
158+- `%bel` - Terminal bell.
159+- `%clr` - Clear screen.
160+- `%hop` - Set cursor position, `p` is its horizontal position on the prompt line.
161+- `%klr` - Styled text, the `$stub` specifies both the text and style.
162+- `%mor` - Multiple `$dill-blit`.
163+- `%pom` - Styled prompt, the `$stub` specifies both the text and style.
164+- `%pro` - Set prompt, `p` is the text for the prompt.
165+- `%qit` - Close console.
166+- `%out` - Print text.
167+- `%sag` - Save `noun` to jamfile. See [$blit](#blit) section for further details.
168+- `%sav` - Save `atom` to file. See [$blit](#blit) section for further details.
169+- `%url` - Activate URL.
170+
171+## `$flog`
172+
173+```hoon
174++$ flog
175+ $% [%crop p=@ud]
176+ [%crud p=@tas q=(list tank)]
177+ [%heft ~]
178+ [%meld ~]
179+ [%pack ~]
180+ [%text p=tape]
181+ [%verb ~]
182+ ==
183+```
184+
185+Wrapped Dill `task`s.
186+
187+These are a subset of Dill's `task`s which can be wrapped in a `%flog` `task`. See the [API Reference](/docs/arvo/dill/tasks) document for details of each of these `task`s.
content/docs/arvo/dill/dill-api.mddeleted−366
@@ -1,366 +0,0 @@
1−+++
2−title = "API Reference"
3−weight = 10
4−template = "doc.html"
5−+++
6−
7−In this document we describe the public interface for Dill. Namely, we describe
8−each `task` that Dill can be `pass`ed, and which `gift`(s) Dill can `give` in return.
9−
10−Dill is unique among vanes since it is technically the first vane to be booted (though we
11−regard Jael as the "true" first vane). As a result, there are four `task`s in
12−`task:able:dill` for which Dill acts only as a middleman that passes the `task`s
13−directly to the Arvo kernel. Thus we have split this document into a [Dill
14−tasks](#dill-tasks) section and an [Arvo tasks](#arvo-tasks) section.
15−
16−## Dill Tasks
17−
18−
19−### `%belt`
20−
21−Every keystroke entered into the console triggers a `%belt` `task` for Dill which contains information about the keystroke, such as which key was pressed
22−and from which terminal.
23−
24−#### Accepts
25−
26−`%belt` `task`s come in a number of different types, corresponding to different
27−keystrokes. You can find this list in `+dill-belt` in `zuse.hoon`.
28−
29−```hoon
30−++ dill-belt :: new belt
31− $% {$aro p/?($d $l $r $u)} :: arrow key
32− {$bac ~} :: true backspace
33− {$cru p/@tas q/(list tank)} :: echo error
34− {$ctl p/@} :: control-key
35− {$del ~} :: true delete
36− {$hey ~} :: refresh
37− {$met p/@} :: meta-key
38− {$ret ~} :: return
39− {$rez p/@ud q/@ud} :: resize, cols, rows
40− {$txt p/(list @c)} :: utf32 text
41− {$yow p/gill:gall} :: connect to app
42− == ::
43−```
44−
45−#### Returns
46−
47−Dill returns no `gift` in response to a `%belt` `task`.
48−
49−
50−### `%blew`
51−
52−This `task` is called whenever the terminal emulator is resized, so that Dill can adjust
53−the text output to fit the new window size.
54−
55−#### Accepts
56−
57−```hoon
58−[p=@ud q=@ud]
59−```
60−
61−`p` is the number of columns and `q` is the number of rows.
62−
63−#### Returns
64−
65−Dill returns no `gift` in response to a `%blew` `task`.
66−
67−
68−### `%boot`
69−
70−This `task` is used only once, when Arvo first enters the [adult
71−stage](/docs/arvo/overview#structural-interface-core). Dill is
72−technically the first vane to be activated, via the `%boot` `task`, which then
73−send Jael (considered the the "true" first vane) an `%init` `task`, which then goes on to
74−call `%init` `task`s for other vanes (including Dill).
75−
76−#### Accepts
77−
78−`%boot` takes an argument that is either `%dawn` or `%fake`. `%dawn` is the one
79−used in any typical scenario and activates the ordinary vane initialization
80−process outlined above, while `%fake` is a debugging tool.
81−
82−#### Returns
83−
84−`%boot` does not return a `gift`.
85−
86−
87−
88−### `%crud`
89−
90−This `task` is used by Dill to produce error reports. It prints the received
91−error message(s) (a `(list tank)`) to the terminal. The level of detail of the
92−error message is set by `$log-level`, which is either `%hush`, `%soft`, or `%loud`.
93−
94−#### Accepts
95−
96−```hoon
97−[err=@tas tac=(list tank)]
98−```
99−
100−`err` is the type of error and `tac` is the associated error message.
101−
102−#### Returns
103−
104−`%crud` does not return a `gift`.
105−
106−
107−### `%flog`
108−
109−A `%flog` `task` is a wrapper over a `task` sent by another vane. Dill removes the wrapper
110−and sends the bare `task` to itself over the default `duct`.
111−
112−#### Accepts
113−
114−`%flog` `task`s can take any valid Dill `task` as an argument.
115−
116−#### Returns
117−
118−`%flog` never returns a `gift` on its own, but the wrapped `task` might.
119−
120−#### Example
121−
122−`%crud` `task`s from other vanes are typically passed to Dill wrapped in a
123−`%flog` `task` to print errors to the terminal.
124−
125−
126−
127−### `%flow`
128−
129−This `task` is not used.
130−
131−
132−### `%hail`
133−
134−`%hail` refreshes the terminal by sending an empty message to the default duct
135−for Dill,
136−causing the terminal to redraw itself (?)
137−
138−#### Accepts
139−
140−```hoon
141−[ ~ ]
142−```
143−
144−#### Returns
145−
146−`%hail` returns no `gift`s.
147−
148−
149−### `%heft`
150−
151−`%heft` causes Dill to `pass` a `%wegh` `task` to all other vanes (but not to
152−itself), thus obtaining a complete digest of Arvo's memory usage.
153−
154−#### Accepts
155−
156−```hoon
157−[ ~ ]
158−```
159−
160−#### Returns
161−
162−`%heft` does not directly return any `gift`s, but each `%wegh` `task` sent will
163−return a `%mass` `gift`.
164−
165−
166−### `%hook`
167−
168−This task is not used.
169−
170−
171−### `%harm`
172−
173−This `task` is not used.
174−
175−
176−### `%init`
177−
178−This `task` is called only once, when Arvo first enters the [adult
179−stage](/docs/arvo/overview#structural-interface-core). It performs
180−initial setup for Dill, such as setting the width of the console.
181−
182−Note that this is not actually the first `task` passed to Dill - see [%boot](#%boot).
183−
184−#### Accepts
185−
186−`%init` takes no arguments.
187−
188−#### Returns
189−
190−`%init` returns no `gift`s.
191−
192−
193−### `%knob`
194−
195−`%knob` sets the verbosity level for each error tag.
196−
197−#### Accepts
198−
199−```hoon
200−[tag=@tas level=log-level]
201−```
202−
203−`tag` is the error tag. `level` is the verbosity, set to either `%hush`,
204−`%soft`, or `%loud`.
205−
206−#### Returns
207−
208−`%knob` does not return a gift.
209−
210−
211−
212−
213−### `%noop`
214−
215−`%noop` does nothing - it stands for "no operation".
216−
217−#### Accepts
218−
219−```hoon
220−[ ~ ]
221−```
222−
223−#### Returns
224−
225−This `task`, predictably, returns nothing.
226−
227−#### Example
228−
229−This can be useful if a shell command requires a Dill `task` but you don't want
230−Dill to do anything.
231−
232−
233−
234−### `%talk`
235−
236−This `task` is not used.
237−
238−### `%text`
239−
240−This `task` prints a `tape` to the dojo by first converting it from a UTF8
241−`tape` to a `list` of UTF32 codepoints (`@c`'s) and then recursively popping off a character from the
242−`tape` and sending it to to Unix to be printed into the terminal via a `%blit` event.
243−
244−#### Accepts
245−
246−```hoon
247−[p=tape]
248−```
249−
250−#### Returns
251−
252−This `task` returns zero or more `%blit` `gift`s, each containing a .
253−
254−
255−### `%trim`
256−
257−`%trim` is a common vane `task` used to reduce memory usage. However, it does
258−nothing for Dill.
259−
260−#### Accepts
261−
262−```hoon
263−[p=@ud]
264−```
265−
266−This is a common parameter for `%trim` `task`s across all vanes but does nothing
267−for Dill.
268−
269−#### Returns
270−
271−This `task` returns no `gift`s.
272−
273−
274−
275−### `%vega`
276−
277−This is a common vane `task` used to inform the vane that the kernel has been
278−upgraded. Dill does not do anything in response to this.
279−
280−#### Accepts
281−
282−```hoon
283−[ ~ ]
284−```
285−
286−#### Returns
287−
288−This `task` returns no `gift`s.
289−
290−
291−
292−## Arvo tasks
293−
294−These `task`s live in `task:able:dill` but are passed directly to the Arvo
295−kernel for processing.
296−
297−### `%lyra`
298−
299−This `task` updates the kernel.
300−
301−#### Accepts
302−
303−```hoon
304−[p=@t q=@t]
305−```
306−
307−`p` is the contents of the new `hoon.hoon` and `q` is the contents of the new `arvo.hoon`.
308−
309−#### Returns
310−
311−This `task` returns no `gift`s.
312−
313−
314−### `%pack`
315−
316−This `task` defragments and deduplicates Arvo's memory. This is ultimately
317−performed by the interpreter so you won't find the code in `arvo.hoon` but
318−rather under `c3__pack` in `urbit/worker/main.c`.
319−
320−#### Accepts
321−
322−```hoon
323−[ ~ ]
324−```
325−
326−#### Returns
327−
328−This `task` returns no `gift`s.
329−
330−
331−### `%veer`
332−
333−This `task` is used to install `zuse` and vanes. It is handled by `+veer` in
334−`arvo.hoon`.
335−
336−#### Accepts
337−
338−```hoon
339−[p=@ta q=path r=@t]
340−```
341−
342−`p` is the vane letter, `q` is the formal `path` to the
343−vane, and `r` is the source code for the vane. The vane letter is `%` followed
344−by the first letter of the vane in lowercase, such as `%d` for Dill. `p=%$` in
345−the case of `zuse`.
346−
347−#### Returns
348−
349−This `task` returns no `gift`s.
350−
351−
352−### `%verb`
353−
354−This `task` toggles verbose mode for all of Arvo, which is located here since
355−Dill is the vane that prints errors. To be precise, `%verb` toggles the laconic
356−bit `lac` in the [Arvo state](/docs/arvo/overview#the-state).
357−
358−#### Accepts
359−
360−```hoon
361−[ ~ ]
362−```
363−
364−#### Returns
365−
366−This `task` returns no `gift`s.
content/docs/arvo/dill/dill.md+35−18
@@ -4,21 +4,38 @@ weight = 1
44template = "doc.html"
55aliases = ["/docs/learn/arvo/dill/"]
66+++
7−Our terminal driver.
8−
9−Unix sends keyboard events to `%dill` from either the console or telnet,
10−and `%dill` produces terminal output. The only app that should directly
11−talk to `%dill` is the terminal app. Command-line apps are run by,
12−receive input from, and produce output to, the `%shell` app, which is
13−controlled by `%terminal`, which talks to `%dill`, which talks to unix.
14−Clay also uses `%dill` directly to print out the filesystem change
15−events, but this is questionable behavior.
16−
17−`%dill` has two main components. First, it controls the terminal on a
18−very basic, event-by-event level. This includes keeping track of things
19−like the dimensions of the terminal, the prompt type (plain text or
20−password), which duct to produce effects on, and so forth. Second, it
21−handles terminal events, keystroke by keystroke. Most characters are
22−simply pushed onto the buffer and blitted to the screen, but some
23−characters, including control-modified keys, arrow keys, etc. require
24−special handling. Most of the readline functionality is in `%dill`.
7+
8+The terminal driver vane.
9+
10+Keyboard events and the like from Unix are received by Dill as [%belt](/docs/arvo/dill/tasks#belt) `task`s, and Dill sends `%blit` `gift`s containing [$blit](/docs/arvo/dill/data-types#blit)s back to the runtime to be displayed in the Unix terminal. The manner of interacting with Dill differs depending on whether you're in userspace or kernelspace, as we'll explore below.
11+
12+## Kernelspace
13+
14+For technical reasons, Dill performs a handful of system tasks related to booting a ship and some memory operations. Aside from those, other Vanes mostly just pass Dill [tasks](/docs/arvo/dill/tasks) to print error messages and the like to the terminal.
15+
16+## Userspace
17+
18+Unlike in kernelspace, userspace applications are unlikely to `%pass` Dill `task`s directly. Instead, Dill looks at things in terms of sessions. A session is a pipeline between a client and a handler, where:
19+
20+- The client is an external input source and output sink; a terminal with with dimensions and so forth.
21+- The handler is an application in Urbit that interprets input, maybe does something with it, maybe produces output to be displayed in the client, etc.
22+
23+There are plans for Dill to support multiple independent sessions (i.e. independent terminal clients displaying and processing different information at the same time), but at this stage Dill only supports a single session. The client for this default session is just the Unix terminal via the Urbit runtime. The handler for the default session is the `%hood` app, whose `drum` module does the heavy lifting.
24+
25+`drum` is the CLI app manager. By default you'll have a couple of CLI applications running—`%dojo` and `%chat-cli`—which you can switch between with `ctrl+x`. You may also have additional CLI apps which you have attached with the `|link` command. It's `drum` that keeps track of which one is active, which one input should be routed to, which one should be displayed, what each prompt should look like, and so forth. Dill itself is oblivious to the distinction between these CLI apps. It only sees the default session with `drum`, so it just passes all input to `drum` and display whatever `drum` gives it.
26+
27+While `drum` talks with Dill in `$dill-belt`s and `$dill-blit`s, it talks to CLI apps with `$sole-action`s and `$sole-event`s, which are defined in the `sole` library. For more information on the `sole` library and the related `shoe` library, and for information on how to build CLI apps, you can refer to the [CLI app tutorial](/docs/hoon/guides/cli-tutorial).
28+
29+To give a basic idea of how keyboard events flow through these systems and produce terminal output, here's a diagram showing the messages in pseudo-Hoon:
30+
31+![Dill userspace diagram](https://media.urbit.org/docs/arvo/dill/dill-userspace.svg)
32+
33+You can use a [move trace](/docs/arvo/tutorials/move-trace) to get a hands-on feel for this data flow.
34+
35+## Sections
36+
37+[API Reference](/docs/arvo/dill/tasks) - The `task`s Dill takes and the `gift`s it returns.
38+
39+[Scry Reference](/docs/arvo/dill/scry) - The scry endpoints of Dill.
40+
41+[Data Types](/docs/arvo/dill/data-types) - Reference documentation of the data types used by Dill.
content/docs/arvo/dill/scry.mdnew file+45
@@ -0,0 +1,45 @@
1++++
2+title = "Scry Reference"
3+weight = 3
4+template = "doc.html"
5++++
6+
7+Here are the scry endpoints of Dill. They take a `%x` `care` and require the `desk` in the path prefix be empty, so the general format is `.^([type] %dx /=//=/[some-path])`.
8+
9+Dill only has a couple of scry endpoints, both of which begin with `/session//`. The empty `//` would be where the target session would be specified, but at this stage Dill can only return a result for the default session, so it's always empty.
10+
11+## /sessions//line
12+
13+A scry with a `care` of `%x` and a `path` of `/sessions//line` returns the current text of the prompt line of the default session. The type returned is a [$blit](/docs/arvo/dill/data-types#blit).
14+
15+#### Example
16+
17+```
18+> .^(blit:dill %dx /=//=/sessions//line)
19+[ %lin
20+ p
21+ ~[
22+ ~-~~
23+ ~-z
24+ ~-o
25+ ~-d
26+ ~-~3a.
27+ ~-d
28+ ~-o
29+ ~-j
30+ ~-o
31+ ...truncated for brevity...
32+ ]
33+]
34+```
35+
36+## /sessions//cursor
37+
38+A scry with a `care` of `%x` and a `path` of `/sessions//cursor` returns the current horizontal position of the cursor in the default session. The type returned is a `@ud`.
39+
40+#### Example
41+
42+```
43+> .^(@ud %dx /=//=/sessions//cursor)
44+44
45+```
content/docs/arvo/dill/tasks.mdnew file+342
@@ -0,0 +1,342 @@
1++++
2+title = "API Reference"
3+weight = 2
4+template = "doc.html"
5++++
6+
7+In this document we describe the public interface for Dill. Namely, we describe each `task` that Dill can be `pass`ed, and which `gift`(s) Dill can `give` in return.
8+
9+## `%belt`
10+
11+```hoon
12+[%belt p=belt]
13+```
14+
15+Terminal input.
16+
17+The runtime sends a `%belt` `task` to Dill whenever there is input in the terminal, such as a keystroke.
18+
19+The [$belt](/docs/arvo/dill/data-types#belt) in `p` contains the input such as which key was pressed.
20+
21+Dill will convert the `$belt` into a [$dill-belt](/docs/arvo/dill/data-types#dill-belt) and `%poke` the session handler (typically `drum`) with it.
22+
23+This `task` would not typically be used from userspace.
24+
25+#### Returns
26+
27+Dill returns no `gift` in response to a `%belt` `task`.
28+
29+## `%blew`
30+
31+```hoon
32+[%blew p=blew]
33+```
34+
35+Terminal resized.
36+
37+The runtime passes Dill a `%blew` `task` whenever the terminal is resized.
38+
39+The [$blew](/docs/arvo/dill/data-types#blew) specifies the new dimensions.
40+
41+Dill will convert the `$blew` into a `%rez` [$dill-belt](/docs/arvo/dill/data-types#dill-belt) and `%poke`s the session handler (typically `drum`) with it.
42+
43+This `task` would not typically be used from userspace.
44+
45+#### Returns
46+
47+Dill returns no `gift` in response to a `%blew` `task`.
48+
49+## `%boot`
50+
51+```hoon
52+[%boot lit=? p=*]
53+```
54+
55+This `task` is used only once, when Arvo first enters the [adult stage](/docs/arvo/overview#structural-interface-core). Dill is technically the first vane to be activated, via the `%boot` `task`, which then sends Jael (considered the "true" first vane) the `%dawn` or `%fake` `task` wrapped in the `%boot` `task`. Jael then goes on to call `%init` `task`s for other vanes (including Dill).
56+
57+`lit` specifies whether to boot in lite mode. `p` is either a [%dawn](/docs/arvo/jael/data-types#dawn) or [%fake](/docs/arvo/jael/tasks#fake) `task:jael`. `%dawn` is for an ordinary boot and `%fake` is for booting a fake ship.
58+
59+This `task` would not be used from userspace.
60+
61+#### Returns
62+
63+Dill returns no `gift` in response to a `%boot` `task`, but it will `%pass` the wrapped `%dawn` or `%fake` `task` to Jael.
64+
65+## `%crop`
66+
67+```hoon
68+[%crop p=@ud]
69+```
70+
71+Trim kernel state.
72+
73+This `task` is the same as the [%trim](#trim) `task`. Like `%trim`, Dill does nothing with it.
74+
75+#### Returns
76+
77+Dill returns no `gift` in response to a `%crop` `task`.
78+
79+## `%crud`
80+
81+```hoon
82+[%crud p=@tas q=(list tank)]
83+```
84+
85+Print error.
86+
87+Dill prints the given error to the terminal. The verbosity for the particular `@tas` error tag specified in `p` is determined by the `level` set by a [%knob](#knob) `task` - either `%hush`, `%soft` or `%loud`. The default is `%loud`, where it will print the full `(list tank)` specified in `q`. See [%knob](#knob) for details of verbosity levels.
88+
89+#### Returns
90+
91+Dill does not return a `gift` in response to a `%crud` `task`.
92+
93+## `%flee`
94+
95+```hoon
96+[%flee session=~]
97+```
98+
99+Unwatch a session to which you've previously subscribed with [%view](#view).
100+
101+The ability to specify a session is not yet implemented in Dill, so `session` is always `~`, the default session.
102+
103+#### Returns
104+
105+Dill does not return a `gift` in response to a `%flee` `task`.
106+
107+## `%flog`
108+
109+```hoon
110+[%flog p=flog]
111+```
112+
113+A `%flog` `task` is a wrapper over a `task` sent by another vane. Dill removes the wrapper and sends the bare `task` to itself over the default `duct`.
114+
115+A `%flog` `task` takes a [$flog](/docs/arvo/dill/data-types#flog) as its argument. A `$flog` is a subset of Dill's `task`s.
116+
117+#### Returns
118+
119+Dill does not return a `gift` in response to a `%flog` `task`.
120+
121+## `%flow`
122+
123+```hoon
124+[%flow p=@tas q=(list gill:gall)]
125+```
126+
127+Terminal config.
128+
129+This `task` is not used.
130+
131+## `%hail`
132+
133+```hoon
134+[%hail ~]
135+```
136+
137+Refresh.
138+
139+Dill converts a `%hail` `task` into a `%hey` [$dill-belt](/docs/arvo/dill/data-types#dill-belt) and `%poke`s the session handler (typically `drum`) with it to handle the refresh.
140+
141+This `task` would not be used from userspace.
142+
143+#### Returns
144+
145+Dill returns no `gift` in response to a `%hail` `task`.
146+
147+## `%heft`
148+
149+```hoon
150+[%heft ~]
151+```
152+
153+Produce memory report.
154+
155+When Dill receives a `%heft` `task` it passes Arvo a `%whey` `waif` to obtain a memory report and prints it to the terminal.
156+
157+#### Returns
158+
159+Dill does not return a `gift` in response to a `%heft` `task`.
160+
161+## `%hook`
162+
163+```hoon
164+[%hook ~]
165+```
166+
167+This terminal hung up.
168+
169+This task is not used.
170+
171+## `%harm`
172+
173+```hoon
174+[%harm ~]
175+```
176+
177+All terminals hung up.
178+
179+This `task` is not used.
180+
181+## `%init`
182+
183+```hoon
184+[%init ~]
185+```
186+
187+This `task` is called only once, when Arvo first enters the [adult stage](/docs/arvo/overview#structural-interface-core). It performs initial setup for Dill, such as setting the width of the console.
188+
189+Note that this is not actually the first `task` passed to Dill - see [%boot](#%boot).
190+
191+This `task` would not be used from userspace.
192+
193+#### Returns
194+
195+Dill does not return a `gift` in response to a `%init` `task`.
196+
197+## `%meld`
198+
199+```
200+[%meld ~]
201+```
202+
203+Deduplicate persistent state.
204+
205+Dill asks the runtime to perform the memory deduplication.
206+
207+#### Returns
208+
209+Dill does not return a `gift` in response to a `%meld` `task`.
210+
211+## `%noop`
212+
213+```hoon
214+[%noop ~]
215+```
216+
217+No operation.
218+
219+A `%noop` `task` does nothing, as the name implies.
220+
221+#### Returns
222+
223+Dill does not return a `gift` in response to a `%noop` `task`.
224+
225+## `%pack`
226+
227+```hoon
228+[%pack ~]
229+```
230+
231+Defragment persistent state.
232+
233+Dill asks the runtime to perform the defragmentation.
234+
235+#### Returns
236+
237+Dill does not return a `gift` in response to a `%meld` `task`.
238+
239+## `%talk`
240+
241+```hoon
242+[%talk p=tank]
243+```
244+
245+This `task` is not used.
246+
247+## `%text`
248+
249+```hoon
250+[%text p=tape]
251+```
252+
253+Print `tape` to terminal.
254+
255+Upon receiving a `%text` `task`, Dill will convert the `tape` given in `p` to a `(list @c)` and give it to the runtime in a `%blit` `gift` including a `%lin` [$blit](/docs/arvo/dill/data-types#blit).
256+
257+#### Returns
258+
259+Dill does not return a `gift` in response to a `%text` `task`, but it does give a `%blit` `gift` to the runtime which looks like:
260+
261+```hoon
262+[%blit p=(list blit)]
263+```
264+
265+## `%view`
266+
267+```hoon
268+[%view session=~]
269+```
270+
271+Watch session.
272+
273+A `%view` `task` subscribes for a copy of all `%blit` `gift`s which Dill `%give`s for the default session. This `task` is used by the `%herm` app so it can convert the `$blit`s to JSON and render them in the web terminal.
274+
275+The ability to specify a session is not yet implemented in Dill, so `session` is always `~`, the default session.
276+
277+#### Returns
278+
279+Dill will `%give` a copy of all `%blit`s for the default session. A `%blit` `gift` is:
280+
281+```hoon
282+[%blit p=(list blit)]
283+```
284+
285+## `%trim`
286+
287+```hoon
288+[%trim p=@ud]
289+```
290+
291+`%trim` is a common vane `task` used to reduce memory usage. It does nothing for Dill because Dill only keeps a minimal necessary state.
292+
293+#### Returns
294+
295+Dill does not return a `gift` in response to a `%trim` `task`.
296+
297+## `%vega`
298+
299+```hoon
300+[%vega ~]
301+```
302+
303+This is a common vane `task` used to inform the vane that the kernel has been
304+upgraded. Dill does not do anything in response to this.
305+
306+This `task` would not be used from userspace.
307+
308+#### Returns
309+
310+Dill returns no `gift` in response to a `%vega` `task`.
311+
312+## `%verb`
313+
314+```hoon
315+[%verb ~]
316+```
317+
318+This `task` toggles verbose mode for all of Arvo, which is located here since
319+Dill is the vane that prints errors. To be precise, `%verb` toggles the laconic
320+bit `lac` in the [Arvo state](/docs/arvo/overview#the-state) by passing a `%verb` `waif` to Arvo.
321+
322+#### Returns
323+
324+Dill does not return a `gift` in response to a `%verb` `task`.
325+
326+## `%knob`
327+
328+```hoon
329+[%knob tag=term level=?(%hush %soft %loud)]
330+```
331+
332+`%knob` sets the verbosity level for each error tag. The error `tag` can be any `@tas`. The given `tag` and `level` will be added to Dill's `veb` which maps tags to levels. Subsequent [%crud](#crud) `task`s will then print with the specified verbosity.
333+
334+The `level`s behave like so:
335+
336+- `%hush` - Completely silent, print nothing.
337+- `%soft` - Just print `crud: %error-tag event failed`, ignore any `tang` given in the `%crud`.
338+- `%loud` - Print the `%soft` message as well as the full `tang` given in the `%crud` `task`.
339+
340+#### Returns
341+
342+Dill does not return a `gift` in response to a `%knob` `task`.