Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #2401 from nickanderson/CFE-3551/3.15.x
CFE-3551/3.15: Fixed inline YAML example and description
  • Loading branch information
nickanderson committed Jan 21, 2021
2 parents ac5db95 + 13f29e0 commit dcc5899
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions reference/promise-types/vars.markdown
Expand Up @@ -215,12 +215,14 @@ For example:
vars:
# JSON or YAML can be inlined since CFEngine 3.7
"inline1" data => '{"key":"value"}'; # JSON
"inline2" data => '---\n- key2: value2'; # YAML requires "---\n" header
"inline2" data => '---
- key2: value2'; # YAML requires "---" header followed by a newline
```

Inline YAML data has to begin with the `---\n` preamble. This preamble
Inline YAML data has to begin with the `---` preamble followed by a newline. This preamble
is normally optional but here (for inline YAML) it's required by
CFEngine.
CFEngine. To generate that in CFEngine, use `$(const.n)` or a literal
newline as shown in the example.

Inline JSON or YAML data may contain CFEngine variable references.
They will be expanded at runtime as if they were simply calls to
Expand Down

0 comments on commit dcc5899

Please sign in to comment.