Skip to content

terraform

This directory provides voice command support for interacting with the Terraform Command Line Interface (CLI). It allows developers and cloud engineers to manage infrastructure-as-code deployments hands-free when working inside a terminal environment.

How It Works

The integration relies on two primary files that work in tandem to define and scope Terraform voice commands:

  • terraform.py: Sets up the programmatic foundation by defining a custom Talon tag, user.terraform_client. This tag serves as a toggle to signal when Terraform commands should be active in the user's current session.
  • terraform.talon: Implements the voice commands. It uses a context header to ensure that these commands are only active when the terminal is open (tag: terminal) and the Terraform client tag has been enabled (tag: user.terraform_client).

Voice Commands

The commands mapped in terraform.talon cover standard lifecycle operations for managing infrastructure, including:

  • Initialization & Validation: Easily run terraform init, upgrade providers with terraform init upgrade, or verify configuration files using terraform validate.
  • Planning & Application: Execute deployment dry-runs using terraform plan, apply changes with terraform apply, or tear down infrastructure via terraform destroy.
  • Formatting & State Management: Clean up code alignment using terraform format (with a recursive option) or manipulate the state file using terraform state move.