Terraform has opinionated style conventions that we should follow, just so that our .tf files look consistent. This commit introduces a pre-commit hook to check the formatting and validity of our .tf files.
Details
Details
Tried to commit invalid terraform code and the hook was triggered
Diff Detail
Diff Detail
- Repository
- rCOMM Comm
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
Comment Actions
Looks good!
scripts/terraform_pre_commit.sh | ||
---|---|---|
10 ↗ | (On Diff #14446) | Just making sure there's a newline at the end of this file, correct? I think Phabricator truncates it by default (just by looking at other JS diffs that have ESLint/Flow checks that ensure a newline is at the end of the file, because Phabricator doesn't show the newline in those either). |
scripts/terraform_pre_commit.sh | ||
---|---|---|
10 ↗ | (On Diff #14446) | Yeah there is, I think phabricator adds a "no new line" warning on the diff if you forget |
Comment Actions
Nice. Can you create tasks for adding these to GitHub Actions and Buildkite? Feel free to leave them as Backlog/unassigned