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

Add autofix support #93

Merged
merged 1 commit into from Jun 13, 2023
Merged

Add autofix support #93

merged 1 commit into from Jun 13, 2023

Conversation

wata727
Copy link
Member

@wata727 wata727 commented May 2, 2023

See also terraform-linters/tflint#1755
See also terraform-linters/tflint-plugin-sdk#254

This PR adds support for autofix in the following rules:

  • terraform_comment_syntax
  • terraform_deprecated_index
  • terraform_deprecated_interpolation
  • terraform_empty_list_equality
  • terraform_required_provider
    • However, only issues with missing source can be fixed
  • terraform_unused_declarations
    • HCL native syntax only

In TFLint v0.47, tflint --fix can automatically fix these issues.

@wata727
Copy link
Member Author

wata727 commented Jun 8, 2023

@bendrucker Could you review this?

If you're interested, you can also review the PRs for the SDK and TFLint core about the autofix feature. If you have any questions, feel free to ask. Thanks!

@bendrucker
Copy link
Member

Will do!

Copy link
Member

@bendrucker bendrucker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great!

@wata727 wata727 merged commit ab8ad03 into main Jun 13, 2023
2 checks passed
@wata727 wata727 deleted the autofix branch June 13, 2023 14:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants