hcledit
« Back to VersTracker
Description:
Command-line editor for HCL
Type: Formula  |  Latest Version: 0.2.17@0  |  Tracked Since: Oct 10, 2025
Links: Homepage  |  formulae.brew.sh
Category: Developer tools
Tags: hcl terraform devops cli utility
Install: brew install hcledit
About:
hcledit is a command-line utility designed for programmatically editing HCL (HashiCorp Configuration Language) files. It operates by parsing HCL into an abstract syntax tree (AST), allowing users to surgically modify specific blocks or attributes. This tool provides a robust alternative to fragile text manipulation with tools like sed or awk.
Key Features:
  • AST-based parsing for safe, structural edits
  • Support for reading, writing, and deleting attributes
  • CLI interface for easy scripting and automation
  • Native support for Terraform and Vault configurations
Use Cases:
  • Automated updates to Terraform variable files
  • Modifying configuration files in CI/CD pipelines
  • Bulk editing of HCL-based infrastructure configs
Alternatives:
  • jq – jq is for JSON, while hcledit is specifically designed for HCL syntax.
  • sed – sed performs regex text replacement, which is error-prone for complex HCL structures.
Version History
Detected Version Rev Change Commit
Oct 10, 2025 2:05pm 0 VERSION_BUMP 3a378f11