Skip to content
| Marketplace
Sign in
Visual Studio Code>Formatters>Terraform Format on SaveNew to Visual Studio Code? Get it now.
Terraform Format on Save

Terraform Format on Save

matheusq94

|
38,599 installs
| (3) | Free
Run terraform fmt on file when it's saved.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Terraform Format on Save

TFS is an extension that will format your terraform code when you save your .tf files.

How it works

It's simply runs terraform fmt <path-to-your-current-file> before saving your .tf or .tfvars files.

Requirements

Terraform installed.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft