-
Notifications
You must be signed in to change notification settings - Fork 321
refactor hcl parser / update commands&outputs for options docs #293
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
docs/options.md
Outdated
``` | ||
|
||
The `--input` flag can also be a good way to see how different input types would be parsed: | ||
|
||
```console | ||
conftest parse examples/hcl2/terraform.tf -i hcl2 | ||
conftest parse examples/hcl/terraform.tf -i hcl |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would better showcase the input flag if the input in the example wasn't the default behavior. If conftest
sees a .hcl
or .tf
file, -i hcl
is to be assumed (which is now the hcl2 parser).
I would actually love to see us renaming the terraform
parser to hcl
, because thats what its really doing.
Then in the examples
, we could have hcl
and/or hcl2
and/or terraform-hcl1
and/or terraform-hcl2
. Not advocating for every single combination, but thats the idea anyway. HCL and HCL2 being the things we parse, and Terraform being an example, but Terraform can be written using HCL1 or HCL2.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
generally agreed, but better to rename terraform
to hcl1
instead of hcl
. Because the hcl
input references to the hcl2
. Using hcl here could be confusing
Thanks for putting this together, @boranx! |
hi @jpreese so the changes so far:
|
I've just gone through the documentation and found some outdated areas.
This PR updates the documentation