Files
2dph/skills/yq/SKILL.md
T
eSliderandGitHub a331042488
Tests / Test (push) Failing after 6s
Tests / OCR (tesseract fixture) (push) Failing after 4s
Tests / Release (semver) (push) Skipped
feat: DuckDB quantiles in-process (gcc CGO), not Ladybug. (#34)
OQ3: internal/duckstats + bin/qa/stats.go. Zig stays Ladybug-only.
mikefarah/yq for small structured slices. Gitea #30.
2026-08-14 11:32:23 +01:00

1.2 KiB

name, description
name description
yq Use https://github.com/mikefarah/yq to work with YAML, JSON, XML, CSV, TOML, HCL where it's efficient and less code. Use when slicing compose, config, --json tool output, CSV/TOML/HCL/XML, or converting between those formats. Not kislyuk Python yq. Not jq when yq already does the job.

yq (mikefarah)

Use https://github.com/mikefarah/yq to work with YAML, JSON, XML, CSV, TOML, HCL where it's efficient and less code.

This is the Go yq (yq --version contains mikefarah). It is not kislyuk/yq (Python, jq-syntax, YAML-only wrapper). bin/db/psql-yq already calls this binary.

Prefer yq over python3 -c, jq, or ad-hoc parsers when one expression reads or converts the file. Keep Python/Go for HTTP, binary protocols, and in-process tests.

yq '.services.picoclaw.image' compose.yaml
yq -P . deploy/picoclaw/config.json          # JSON → YAML
yq -o=json '.gates'                           # JSON stdin (qa/system_perf.py --json)
yq -p=csv -o=json .
yq -p=xml -o=json .
yq -p=toml '.package.name' file.toml
bin/brain/search.go "LadybugDB" --json | yq '.[].ref'
bin/web/search.go "hypervisor" --json | yq -r '.results[].url'

Do not print secrets, PII, or $HOME/.config/brain/ through yq.