# 使用 Homebrew 安装 terraform-cleaner

查看 terraform-cleaner 的安装路径、可执行文件、元数据以及面向 AI 代理工作流的安全说明。

## 安装

```sh
sudo av install brew:terraform-cleaner
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install terraform-cleaner
```

  证据: local Homebrew formula metadata

## 软件包事实

- **软件包键:** brew:terraform-cleaner
- **软件包管理器:** Homebrew
- **版本:** 0.0.4
- **来源摘要:** Tiny utility which detects unused variables in your terraform modules
- **主页:** <https://github.com/sylwit/terraform-cleaner>
- **仓库:** <https://github.com/sylwit/terraform-cleaner>
- **最后更新:** 2026-07-26T00:50:35+02:00
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- terraform-cleaner (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

- 页面生成时间: 2026-08-03
- 管理器版本: 0.0.4
## 项目历史与用法

terraform-cleaner is a small Go CLI for detecting unused variables in Terraform modules. Its public history is short and narrowly scoped, but official repository and release metadata are sufficient to describe it as a focused Terraform hygiene utility.

### 项目历史

The repository was created in March 2023. Its README describes it as a tiny utility for finding unused variables in Terraform modules and points users to GitHub releases for platform binaries.

The complete release history is compact: v0.0.1 included the first working version and GoReleaser setup, v0.0.2 adjusted unused-flag display behavior, v0.0.3 added display of locals and unused locals, and v0.0.4 fixed help messages and added an asciinema demo to the README.

### 采用历史

The input package facts show Homebrew packaging, and the README documents binary downloads from the GitHub releases page. There is no official evidence of a large ecosystem around the tool; its adoption appears to be the usual package-manager exposure for a small Terraform developer utility.

### 使用方式

The README keeps usage deliberately minimal: download a platform binary from releases and run the tool against Terraform modules to find unused variables. It also documents pre-commit hook installation, suggesting use as part of a local Terraform cleanup workflow.

### 为什么软件包爱好者会关心

terraform-cleaner matters in the package-nerd niche as a small, single-purpose IaC linting helper. It is the kind of utility package maintainers include because it automates one annoying Terraform maintenance check without introducing a larger framework.

### 时间线

- 2023: GitHub repository created.
- 2023: v0.0.1 released with the first working version and GoReleaser setup.
- 2023: v0.0.3 added display of locals and unused locals.
- 2023: v0.0.4 fixed help messages and updated the README with an asciinema demo.

### Related projects

- terraform-cleaner belongs to the Terraform linting and cleanup tool family, adjacent to Terraform module maintenance workflows and pre-commit usage.
- It is much narrower than TerraCognita: TerraCognita imports existing infrastructure into Terraform, while terraform-cleaner checks module source for unused variables.

### 来源

- <https://api.github.com/repos/sylwit/terraform-cleaner>
- <https://api.github.com/repos/sylwit/terraform-cleaner/releases?per_page=20>
- <https://github.com/sylwit/terraform-cleaner>
- <https://raw.githubusercontent.com/sylwit/terraform-cleaner/main/README.md>
- source_facts.package-manager


## 安全说明

narrow executable package without higher-risk signals.

- **Geiger 风险:** 绿色 / 低
- narrow executable package without higher-risk signals


## Combined YAML source

View the package source record on GitHub. [combined/terraform-cleaner.yml](https://github.com/mxcl/pkgdb/blob/main/combined/terraform-cleaner.yml)


## 来源

- pkg.so package database
- Geiger risk classifier
- curated package history
- pkgdb category and tag curation
- cross-ecosystem install command graph
