hcl/cmd/hcldec/examples/sh-config-file/spec.hcldec
Martin Atkins ee147d9ee6 cmd/hcldec: Command-line tool for converting HCL config to JSON
This is essentially a CLI wrapper around the hcldec package, accepting a
decoding specification via a HCL-based language and using it to translate
input HCL files into JSON values while performing basic structural and
type validation of the input files.
2018-02-03 15:37:11 -08:00

24 lines
345 B
Plaintext

object {
attr "name" {
type = string
required = true
}
default "greeting" {
attr {
name = "greeting"
type = string
}
literal {
value = "Hello"
}
}
block_list "friends" {
block_type = "friend"
attr {
name = "name"
type = string
required = true
}
}
}