You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Notice in the first example that there are no [] around the terraform subkeys. When I pipe this output to jq -r '.terraform' it works as expected but if I filter for a subkey like '.terraform.required_version' I get this error which I believe is due to the [] output from your tool.
root@0de8e7724845:~# ./go/bin/hcl2json ./test.tf |jq -r '.terraform'
Example using HCL2JSON from NPM on osx
$cat ./0-terraform.tf
$ hcl2json ./0-terraform.tf
Here are the same file contents and the JSON output using your HCL2JSON on a Ubuntu Trusty docker container.
root@0de8e7724845:~# cat test.tf
root@0de8e7724845:~# ./go/bin/hcl2json ./test.tf
Notice in the first example that there are no [] around the terraform subkeys. When I pipe this output to jq -r '.terraform' it works as expected but if I filter for a subkey like '.terraform.required_version' I get this error which I believe is due to the [] output from your tool.
root@0de8e7724845:~# ./go/bin/hcl2json ./test.tf |jq -r '.terraform'
root@0de8e7724845:~# ./go/bin/hcl2json ./test.tf |jq -r '.terraform.required_version'
The text was updated successfully, but these errors were encountered: