Closed d-helios closed 4 years ago
I got a minimal reproduction code like the following:
variable "foo" {
default = "foo"
}
foo = "%{if true}${var.foo}%{endif}"
And I created the PR to HCL repository https://github.com/hashicorp/hcl2/pull/125 Maybe it fixes the issue.
(Reopening because the change in the HCL repository can't fix this until it's vendored into this repository.)
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
terraform fmt command insert space (" ") character in inline template
Terraform Version
Terraform Configuration Files
Expected Behavior
terraform fmt doesn't insert any additional character in inline templates (string)
Actual Behavior
Steps to Reproduce
Please list the full steps required to reproduce the issue, for example:
terraform init
cp main.tf /tmp/main.tf
terraform fmt
diff /tmp/main.tf main.tf