@@ -33,7 +33,7 @@ template = "doc.html"
34# Introduction
34# Introduction
36−This document details all the `task`s you're likely to use to interact with Clay, as well as the `gift`s you'll receive in response. Each section has a corresponding practical example in the [Examples](@/docs/arvo/clay/examples.md) document. Many of the types referenced are detailed in the [Data Types](@/docs/arvo/clay/data-types.md) document. It may also be useful to look at the `++ clay` section of `/sys/lull.hoon` in Arvo where these `task`s, `gift`s and data structures are defined.
36+This document details all the `task`s you're likely to use to interact with Clay, as well as the `gift`s you'll receive in response. Each section has a corresponding practical example in the [Examples](/docs/arvo/clay/examples) document. Many of the types referenced are detailed in the [Data Types](/docs/arvo/clay/data-types) document. It may also be useful to look at the `++ clay` section of `/sys/lull.hoon` in Arvo where these `task`s, `gift`s and data structures are defined.
38The focus of this document is on interacting with Clay from userspace applications and threads, so it doesn't delve into the internal mechanics of Clay from a kernel development perspective.
38The focus of this document is on interacting with Clay from userspace applications and threads, so it doesn't delve into the internal mechanics of Clay from a kernel development perspective.
@@ -47,7 +47,7 @@ A `%warp` `task` is for reading a subscribing to files and directories.
47[wer=ship rif=riff]
47[wer=ship rif=riff]
50−The `wer` field is the target ship. The `(unit rave)` of the [riff](@/docs/arvo/clay/data-types.md#riff-clay-request-desist) is null to cancel an existing subscription, otherwise the [rave](@/docs/arvo/clay/data-types.md#rave-clay-general-subscription-request) is tagged with one of:
50+The `wer` field is the target ship. The `(unit rave)` of the [riff](/docs/arvo/clay/data-types#riff-clay-request-desist) is null to cancel an existing subscription, otherwise the [rave](/docs/arvo/clay/data-types#rave-clay-general-subscription-request) is tagged with one of:
52- `%sing` - Read a single file or directory.
52- `%sing` - Read a single file or directory.
53- `%next` - Subscribe for the next change to a file or directory.
53- `%next` - Subscribe for the next change to a file or directory.
@@ -72,25 +72,25 @@ A `%wris` `gift` looks like:
72[%writ p=riot] :: response
72[%writ p=riot] :: response
75−The `unit` of the [riot](@/docs/arvo/clay/data-types.md#riot-clay-response) will be null if the target file cannot be found or if a subscription has ended (depending on context). Otherwise it will have a [rant](@/docs/arvo/clay/data-types.md#rant-clay-response-data) with a `cage` containing the data you requested. Its contents will vary depending on the kind of request and `care`.
75+The `unit` of the [riot](/docs/arvo/clay/data-types#riot-clay-response) will be null if the target file cannot be found or if a subscription has ended (depending on context). Otherwise it will have a [rant](/docs/arvo/clay/data-types#rant-clay-response-data) with a `cage` containing the data you requested. Its contents will vary depending on the kind of request and `care`.
77Now we'll look at each of the `rave` request types in turn.
77Now we'll look at each of the `rave` request types in turn.
82−[%sing =mood]
82+[%sing =mood]
85This `rave` is for reading a single file or directory immediately.
85This `rave` is for reading a single file or directory immediately.
87−The `care` of the [mood](@/docs/arvo/clay/data-types.md#mood-clay-single-subscription-request) will determine what you can read and what type of data will be returned. See the [care](@/docs/arvo/clay/data-types.md#care-clay-clay-submode) documentation and [scry](@/docs/arvo/clay/scry.md) documentation for details on the various `care`s.
87+The `care` of the [mood](/docs/arvo/clay/data-types#mood-clay-single-subscription-request) will determine what you can read and what type of data will be returned. See the [care](/docs/arvo/clay/data-types#care-clay-clay-submode) documentation and [scry](/docs/arvo/clay/scry) documentation for details on the various `care`s.
89−The [case](@/docs/arvo/clay/data-types.md#case-specifying-a-commit) specifies the `desk` revision and you can use whichever kind you prefer. The `path` will usually be a path to a file or directory like `/gen/hood/hi/hoon` but may be something else depending on the `care`.
89+The [case](/docs/arvo/clay/data-types#case-specifying-a-commit) specifies the `desk` revision and you can use whichever kind you prefer. The `path` will usually be a path to a file or directory like `/gen/hood/hi/hoon` but may be something else depending on the `care`.
91### Example
91### Example
93−[See here for an example of using %sing.](@/docs/arvo/clay/examples.md#sing)
93+[See here for an example of using %sing.](/docs/arvo/clay/examples#sing)
@@ -98,13 +98,13 @@ The [case](@/docs/arvo/clay/data-types.md#case-specifying-a-commit) specifies th
98[%next =mood] :: await next version
98[%next =mood] :: await next version
101−This subscribes to the next version of the specified file. See [here](@/docs/arvo/clay/data-types.md#mood-clay-single-subscription-request) for details of the `mood` structure.
101+This subscribes to the next version of the specified file. See [here](/docs/arvo/clay/data-types#mood-clay-single-subscription-request) for details of the `mood` structure.
103If you subscribe to the current `case` of the `desk`, Clay will not respond until the file changes. If you subscribe to a previous `case` of the `desk` and the file has changed in between then and now, it will immediately return the first change it comes across in that range. For example, if you're currently at `case` `100`, subscribe to case `50` and the file in question has been modified at both `60` and `80`, clay will immediately return the version of the file at `case` `60`.
103If you subscribe to the current `case` of the `desk`, Clay will not respond until the file changes. If you subscribe to a previous `case` of the `desk` and the file has changed in between then and now, it will immediately return the first change it comes across in that range. For example, if you're currently at `case` `100`, subscribe to case `50` and the file in question has been modified at both `60` and `80`, clay will immediately return the version of the file at `case` `60`.
105### Example
105### Example
107−[See here for an example of using %next.](@/docs/arvo/clay/examples.md#next)
107+[See here for an example of using %next.](/docs/arvo/clay/examples#next)
109## `%mult`
109## `%mult`
@@ -126,7 +126,7 @@ You can use a different `care` for each of the files specified by the `path` if
127### Example
127### Example
129−[See here for an example of using %mult.](@/docs/arvo/clay/examples.md#mult)
129+[See here for an example of using %mult.](/docs/arvo/clay/examples#mult)
131## `%many`
131## `%many`
@@ -144,9 +144,9 @@ If the `track` is `%.y` it will just return a `%writ` like:
145...that merely informs you of a change. If you want the actual data you'll have to request it separately.
145...that merely informs you of a change. If you want the actual data you'll have to request it separately.
147−If the `track` is `%.n`, the `cage` of the `%writ` will contain a [nako](@/docs/arvo/clay/data-types.md#nako-subscription-response-data) with the relevant data for all changes to a desk between what you have and the `case` requested. It is very large and fairly complicated. The `nako` structure is defined in the `clay.hoon` source file itself rather than in `lull.hoon` or elsewhere since you're unlikely to work with it yourself.
147+If the `track` is `%.n`, the `cage` of the `%writ` will contain a [nako](/docs/arvo/clay/data-types#nako-subscription-response-data) with the relevant data for all changes to a desk between what you have and the `case` requested. It is very large and fairly complicated. The `nako` structure is defined in the `clay.hoon` source file itself rather than in `lull.hoon` or elsewhere since you're unlikely to work with it yourself.
149−The `from` and `to` fields of the [moat](@/docs/arvo/clay/data-types.md#moat-clay-range-subscription-request) specify the range of `case`s for which to subscribe. The range is *inclusive*. It can be specified by date or by revision number, whichever you prefer.
149+The `from` and `to` fields of the [moat](/docs/arvo/clay/data-types#moat-clay-range-subscription-request) specify the range of `case`s for which to subscribe. The range is *inclusive*. It can be specified by date or by revision number, whichever you prefer.
151The `path` in the `moat` is a path to a file or directory. If it's `~` it refers to the root of the `desk` in question. This lets you say "only inform me of changes to the `desk` if the specified file or directory exists". If it doesn't exist, Clay will not send you anything.
151The `path` in the `moat` is a path to a file or directory. If it's `~` it refers to the root of the `desk` in question. This lets you say "only inform me of changes to the `desk` if the specified file or directory exists". If it doesn't exist, Clay will not send you anything.
@@ -158,7 +158,7 @@ When you reach the end of the subscribed range of `case`s, Clay will send you a
159### Example
159### Example
161−[See here for an example of using %many.](@/docs/arvo/clay/examples.md#many)
161+[See here for an example of using %many.](/docs/arvo/clay/examples#many)
163## Cancel Subscription
163## Cancel Subscription
@@ -166,7 +166,7 @@ To cancel a subscription, you just send a `%warp` with a null `(unit rave)` in t
167### Example
167### Example
169−[See here for an example of cancelling a subscription.](@/docs/arvo/clay/examples.md#cancel-subscription)
169+[See here for an example of cancelling a subscription.](/docs/arvo/clay/examples#cancel-subscription)
171# Write and Modify
171# Write and Modify
@@ -180,7 +180,7 @@ To write or modify a file, we send Clay a `%info` `task`.
180[des=desk dit=nori]
180[des=desk dit=nori]
183−The `%|` tag in the [nori](@/docs/arvo/clay/data-types.md#nori-clay-repository-action) is not currently supported and will crash with a `%labelling-not-implemented` if used, so you can focus on the `%&` part. The [soba](@/docs/arvo/clay/data-types.md#soba-clay-delta) in the `nori` is just a list of changes so you can make more than one change in one request. Its `path` is just the path to a file like `/gen/hood/hi/hoon` and the [miso](@/docs/arvo/clay/data-types.md#miso-clay-ankh-delta) is one of these types of requests:
183+The `%|` tag in the [nori](/docs/arvo/clay/data-types#nori-clay-repository-action) is not currently supported and will crash with a `%labelling-not-implemented` if used, so you can focus on the `%&` part. The [soba](/docs/arvo/clay/data-types#soba-clay-delta) in the `nori` is just a list of changes so you can make more than one change in one request. Its `path` is just the path to a file like `/gen/hood/hi/hoon` and the [miso](/docs/arvo/clay/data-types#miso-clay-ankh-delta) is one of these types of requests:
185- `%del` - Delete a file.
185- `%del` - Delete a file.
186- `%ins` - Insert file. This will also replace an existing file.
186- `%ins` - Insert file. This will also replace an existing file.
@@ -195,10 +195,10 @@ Clay does not give any response to an `%info` `task` so don't expect a `sign` ba
196Here are examples of using each of these as well as making multiple changes in one request:
196Here are examples of using each of these as well as making multiple changes in one request:
198−- [%del](@/docs/arvo/clay/examples.md#del)
198+- [%del](/docs/arvo/clay/examples#del)
199−- [%ins](@/docs/arvo/clay/examples.md#ins)
199+- [%ins](/docs/arvo/clay/examples#ins)
200−- [%mut](@/docs/arvo/clay/examples.md#mut)
200+- [%mut](/docs/arvo/clay/examples#mut)
201−- [Multiple Changes](@/docs/arvo/clay/examples.md#multiple-changes)
201+- [Multiple Changes](/docs/arvo/clay/examples#multiple-changes)
204# Manage Mounts
204# Manage Mounts
@@ -236,7 +236,7 @@ The type it returns is a `%hill` `gift`, which looks like:
237### Example
237### Example
239−[See here for an example of using %boat.](@/docs/arvo/clay/examples.md#boat)
239+[See here for an example of using %boat.](/docs/arvo/clay/examples#boat)
241## `%mont`
241## `%mont`
@@ -263,11 +263,11 @@ Clay does not return a `gift` in response to a `%mont` `%task`.
264### Example
264### Example
266−[See here for an example of using %mont.](@/docs/arvo/clay/examples.md#mont)
266+[See here for an example of using %mont.](/docs/arvo/clay/examples#mont)
268## `%ogre`
268## `%ogre`
270−A `%ogre` `task` unmounts the specified mount.
270+A `%ogre` `task` unmounts the specified mount.
272### Accepts
272### Accepts
@@ -283,7 +283,7 @@ Clay does not return a `gift` in response to a `%ogre` `task`.
284### Example
284### Example
286−[See here for an example of using %ogre.](@/docs/arvo/clay/examples.md#ogre)
286+[See here for an example of using %ogre.](/docs/arvo/clay/examples#ogre)
288## `%dirk`
288## `%dirk`
@@ -303,7 +303,7 @@ Clay does not return a `gift` in response to a `%dirk` `task`.
304### Example
304### Example
306−[See here for an example of using %dirk.](@/docs/arvo/clay/examples.md#dirk)
306+[See here for an example of using %dirk.](/docs/arvo/clay/examples#dirk)
308# Merge Desks
308# Merge Desks
@@ -319,7 +319,7 @@ $: des=desk :: target
319 how=germ :: method
319 how=germ :: method
322−The `germ` specifies the merge strategy. You can refer to the [Strategies](@/docs/arvo/clay/using.md#strategies) section of the [Using Clay](@/docs/arvo/clay/using.md) document for details of each `germ`.
322+The `germ` specifies the merge strategy. You can refer to the [Strategies](/docs/arvo/clay/using#strategies) section of the [Using Clay](/docs/arvo/clay/using) document for details of each `germ`.
324If you're merging into a new `desk` you must use `%init`, all other strategies will fail. If the desk already exists, you cannot use `%init`. Otherwise, you're free to use whichever you'd like.
324If you're merging into a new `desk` you must use `%init`, all other strategies will fail. If the desk already exists, you cannot use `%init`. Otherwise, you're free to use whichever you'd like.
@@ -346,7 +346,7 @@ If the merge failed, `p` will have a head of `%.n` and then a `[term tang]` wher
347### Example
347### Example
349−[See here for an example of using %merg.](@/docs/arvo/clay/examples.md#merg)
349+[See here for an example of using %merg.](/docs/arvo/clay/examples#merg)
351# Permissions
351# Permissions
@@ -431,7 +431,7 @@ Clay does not return a `gift` in response to a `%perm` `task`.
432### Example
432### Example
434−[See here for an example of using %perm.](@/docs/arvo/clay/examples.md#perm)
434+[See here for an example of using %perm.](/docs/arvo/clay/examples#perm)
436## `%cred`
436## `%cred`
@@ -455,7 +455,7 @@ Clay does not return a `gift` in response to a `%cred` `task`.
456### Example
456### Example
458−[See here for an example of using %cred.](@/docs/arvo/clay/examples.md#cred)
458+[See here for an example of using %cred.](/docs/arvo/clay/examples#cred)
460## `%crew`
460## `%crew`
@@ -481,7 +481,7 @@ The `cez` is just a map from group name to `crew` which is just a `(set ship)`.
482### Example
482### Example
484−[See here for an example of using %crew.](@/docs/arvo/clay/examples.md#crew)
484+[See here for an example of using %crew.](/docs/arvo/clay/examples#crew)
486## `%crow`
486## `%crow`
@@ -511,7 +511,7 @@ The `gift` you get back is a `%croz` which looks like:
512### Example
512### Example
514−[See here for an example of using %crow.](@/docs/arvo/clay/examples.md#crow)
514+[See here for an example of using %crow.](/docs/arvo/clay/examples#crow)
516# Foreign Ships
516# Foreign Ships
@@ -540,7 +540,7 @@ Note that if you're reading a whole `desk` or directory, all subfolders and file
541### Example
541### Example
543−[See here for examples of requests to foreign ships.](@/docs/arvo/clay/examples.md#foreign-ships)
543+[See here for examples of requests to foreign ships.](/docs/arvo/clay/examples#foreign-ships)
545## `%merg` - Remote
545## `%merg` - Remote
@@ -552,4 +552,4 @@ Note that all subfolders and individual files within the `desk` must permit your
553### Example
553### Example
555−[See here for examples of requests to foreign ships.](@/docs/arvo/clay/examples.md#foreign-ships)
555+[See here for examples of requests to foreign ships.](/docs/arvo/clay/examples#foreign-ships)