-
Notifications
You must be signed in to change notification settings - Fork 5
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
Preserve comments #36
Comments
Hey @nikolaik, I understand that people often use comments to logically group variable blocks based on their purposes, such as RDS-related vars or SQS-related vars. However, when we decide to sort variables alphabetically - using comments doesn't make much sense anymore. Terraform's I would be interested in hearing more about how you envision this implementation. It would be helpful to see some code examples before and after the proposed changes. Thank you again for your feedback! |
If the comments were declared inside of the |
@timduhenchanter Well, I think I don't understand the request. If the comment is declared within the variable or outputs block, tfsort will preserve them. Did you mean some specific scenario? |
Thanks for the reply @AlexNabokikh.
That is our main use case for comments in
One grouping I often see are required variables, but I'm not sure if that is worth the hassle. Moving all of the comments to the top of the file might be less surprising, than stripping them completely |
I use # tflint-ignore: terraform_naming_convention
output "EXAMPLE" {
value = "example"
description = "example"
} It would be great if |
Hi and thanks for this nice little tool. Would love it if could also preserve comments
The text was updated successfully, but these errors were encountered: