toml-editor
Installation
SKILL.md
TOML Editor
Edit .toml files without shell escaping issues. Three tools available:
| Tool | Lang | In-place | Pros | Reference |
|---|---|---|---|---|
| toml-cli | Rust | No (prints) | Format-preserving, comments intact | references/toml-cli.md |
| yq | Python | Yes (-i) |
jq-like syntax, widely known | references/yq.md |
| tmq | Go | Yes | Zero-dependency binary, fast | references/tmq.md |
Recommendation: Prefer toml-cli for Pi-hole configs and other human-edited files where comment preservation matters. Prefer yq -t -i for automated transformations (CI, scripts). Pull the reference doc for your chosen tool above.
Installation (one-time)
# toml-cli — Rust
cargo install toml-cli
# or no-install: npx @toml-tools/editor set config.toml key "value"