From 5c92cef983ef3ba8e4ffd1b745e2da608efe1f69 Mon Sep 17 00:00:00 2001 From: James Shubin Date: Sat, 12 Jan 2019 11:44:58 -0500 Subject: [PATCH] docs: Add sub categories to the language guide Hopefully this makes the longer sections easier to read. --- docs/language-guide.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/language-guide.md b/docs/language-guide.md index bed1be66..d46710ae 100644 --- a/docs/language-guide.md +++ b/docs/language-guide.md @@ -190,6 +190,8 @@ resource to control how it behaves. For example, setting the `content` parameter of a `file` resource to the string `hello`, will cause the contents of that file to contain the string `hello` after it has run. +##### Undefined parameters + For some parameters, there is a distinction between an unspecified parameter, and a parameter with a `zero` value. For example, for the file resource, you might choose to set the `content` parameter to be the empty string, which would @@ -214,6 +216,8 @@ it evaluates to `true`, then the parameter will be used. If no `elvis` operator is specified, then the parameter value will also be used. If the parameter is not specified, then it will obviously not be used. +##### Meta parameters + Resources may specify meta parameters. To do so, you must add them as you would a regular parameter, except that they start with `Meta` and are capitalized. Eg: @@ -258,6 +262,8 @@ Please note that at the moment, you must specify a full metaparams struct, since partial struct types are currently not supported in the language. Patches are welcome if you'd like to add this tricky feature! +##### Internal edges + Resources may also declare edges internally. The edges may point to or from another resource, and may optionally include a notification. The four properties are: `Before`, `Depend`, `Notify` and `Listen`. The first two represent normal