Skip to content

Installation

TerraTidy can be installed in several ways.

Go Install

If you have Go installed (1.26+):

go install github.com/santosr2/TerraTidy/cmd/terratidy@v0.4.0

Pin your version

Pin to an explicit version tag for reproducible installs rather than tracking a floating reference.

Homebrew (macOS/Linux)

brew install --cask santosr2/tap/terratidy

Since Homebrew 6.0.0, third-party taps must be trusted before their contents will load. Installing by the fully qualified name grants that trust to this cask alone, which is why there is no separate brew tap step. To install by short name, trust the tap first with brew trust santosr2/tap, which accepts everything it ships now and in future.

Download Binary

Download pre-built binaries from the GitHub Releases page.

Linux (amd64)

curl -LO https://github.com/santosr2/TerraTidy/releases/latest/download/terratidy_linux_amd64.tar.gz
tar xzf terratidy_linux_amd64.tar.gz
sudo mv terratidy /usr/local/bin/

macOS (Apple Silicon)

curl -LO https://github.com/santosr2/TerraTidy/releases/latest/download/terratidy_darwin_arm64.tar.gz
tar xzf terratidy_darwin_arm64.tar.gz
sudo mv terratidy /usr/local/bin/

Windows

# Download the latest release
Invoke-WebRequest -Uri "https://github.com/santosr2/TerraTidy/releases/latest/download/terratidy_windows_amd64.zip" -OutFile "terratidy.zip"

# Extract the archive
Expand-Archive -Path "terratidy.zip" -DestinationPath "."

# Move to a directory in your PATH (e.g., C:\Program Files\TerraTidy)
New-Item -ItemType Directory -Force -Path "C:\Program Files\TerraTidy"
Move-Item -Path "terratidy.exe" -Destination "C:\Program Files\TerraTidy\"

# Add to PATH (run as Administrator)
[Environment]::SetEnvironmentVariable("Path", $env:Path + ";C:\Program Files\TerraTidy", "Machine")

Docker

# Pin to a specific version (recommended)
docker pull ghcr.io/santosr2/terratidy:v0.4.0

# Or track the most recent stable release
docker pull ghcr.io/santosr2/terratidy:latest

docker run --rm -v $(pwd):/app ghcr.io/santosr2/terratidy check

Verify Installation

terratidy version

Every release includes checksums, cosign signatures, SBOMs, and build provenance attestations. See Verification for details on how to verify artifact integrity.

Next Steps