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

Run the output through terraform fmt #36

Open
jrhouston opened this issue Oct 16, 2021 · 1 comment
Open

Run the output through terraform fmt #36

jrhouston opened this issue Oct 16, 2021 · 1 comment
Labels
enhancement New feature or request

Comments

@jrhouston
Copy link
Owner

Right now the output doesn't get format, so attributes don't get aligned and so on. We should programatically run terraform fmt so that the tfk8s output doesn't need to be formatted.

@jrhouston jrhouston added the enhancement New feature or request label Oct 16, 2021
@jrhouston
Copy link
Owner Author

The logic behind terraform fmt is internal, and looks like a significant amount of code to have to copy over 😓 https://github.com/hashicorp/terraform/blob/7d3074df46b3d3351424a3b44df590fdcbbc6aad/internal/command/fmt.go#L271

terraform fmt does however support reading from STDIN, so we could use terraform-exec which supports the fmt feature. This requires tfk8s to find or download the terraform binary which kind of sucks, though.

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

No branches or pull requests

1 participant