Development

Local development setup for the yeet repo.

This page is for local dev on the yeet repo.

Toolchain (recommended: mise)

If you already have Go in your PATH, you can skip mise and use the Go commands below. Otherwise:

curl https://mise.run | sh
echo 'eval "$(mise activate zsh)"' >> ~/.zshrc

Swap zsh for your shell (bash/fish/etc.) if needed.

From the repo root, install tools (Go 1.26.2):

mise install
mise run install-githooks

The hook install uses pre-commit and sets up both the pre-commit and prepare-commit-msg hook types. It also clears any existing core.hooksPath so pre-commit can manage the hooks.

Build

go build ./cmd/yeet
go build ./cmd/catch

Test

go test ./...

Quality gate

The pre-commit hook also runs the repo quality gate:

mise run quality

That command scans for private local references, runs Go tests with coverage, checks CRAP hotspots, runs golangci-lint with complexity and bug-risk linters, and writes a churn/coverage hotspot report to .tmp/quality/hotspots.txt. Existing findings are baselined in tools/quality/baseline/, so new complexity, coverage-risk, or lint findings fail while older hotspots can be burned down over time.

After intentionally fixing baseline entries, refresh the tracked baseline:

mise run quality:baseline

Heavier empirical checks are available outside the normal pre-commit path:

mise run race
mise run fuzz
mise run mutation
mise run hotspots

The longer-term quality goal is stricter than the ratchet: at least 80% total coverage, zero CRAP hotspots, zero golangci findings, 80% mutation score on the bounded mutation target set, the race detector passing, and at least four active fuzz targets. To see whether the repo has reached that destination, run:

mise run quality:goal

Run locally

Run catch in the foreground with a local data dir:

go run ./cmd/catch --data-dir ./data

Run yeet against a target host:

CATCH_HOST=<host> go run ./cmd/yeet status

Notes

  • Most CLI behavior is in cmd/yeet and pkg/cli.
  • RPC handling lives in pkg/catch and pkg/catchrpc.