Skip to content
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

Json2hcl reverse is not working. #23

Open
roylkng opened this issue Sep 9, 2022 · 2 comments
Open

Json2hcl reverse is not working. #23

roylkng opened this issue Sep 9, 2022 · 2 comments

Comments

@roylkng
Copy link

roylkng commented Sep 9, 2022

I tried reverse on the tf file in the fixtures, but it gets stuck without any output.

@Acconut
Copy link
Collaborator

Acconut commented Sep 9, 2022

Thank you for this report, but as stated in the README:

We don't use json2hcl anymore ourselves, so we can't invest time into it. However, we're still welcoming PRs.

@gtirloni
Copy link

gtirloni commented Nov 4, 2023

Adding a test case if someone wants to fix this.

$ cat test-vars.tf 
variable "my_var" {
  type        = string
  description = "This is a variable"
  default     = "foo"
}

$ terraform fmt test-vars.tf

$ cat test-vars.tf | json2hcl -reverse
unable to parse HCL: At 2:17: Unknown token: 2:17 IDENT string

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants