523939034f
This package implements a language extension that allows configuration authors to include the content of another file into a body, using syntax like this: include { path = "./foo.zcl" } This is implemented as a transform.Transformer so that it can be used as part of a transform chain when decoding nested block structures to allow includes at any arbitrary point. This capability is not built into the language because certain applications will offer higher-level constructs for connecting multiple separate config files, which may e.g. have a separate evaluation scope for each file, etc.
13 lines
424 B
Go
13 lines
424 B
Go
// Package include implements a zcl extension that allows inclusion of
|
|
// one zcl body into another using blocks of type "include", with the following
|
|
// structure:
|
|
//
|
|
// include {
|
|
// path = "./foo.zcl"
|
|
// }
|
|
//
|
|
// The processing of the given path is delegated to the calling application,
|
|
// allowing it to decide how to interpret the path and which syntaxes to
|
|
// support for referenced files.
|
|
package include
|