Skip to content

Installation

TerraTidy can be installed in several ways.

Go Install

If you have Go installed (1.25+):

# Use explicit version until v0.2.0 stable
go install github.com/santosr2/TerraTidy/cmd/terratidy@v0.2.0-alpha.4

Avoid @latest until v0.2.0

Due to a repository rename after v0.1.0, go install ...@latest resolves to v0.1.0 which has a broken module path. Use an explicit pre-release version until v0.2.0 stable is released.

Homebrew (macOS/Linux)

brew tap santosr2/tap https://github.com/santosr2/TerraTidy
brew install santosr2/tap/terratidy

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

# latest always points to the most recent stable release
docker pull ghcr.io/santosr2/terratidy:latest

# Pin to a specific version (recommended)
docker pull ghcr.io/santosr2/terratidy:v0.2.0-alpha.4

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