Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Development Setup

Audience: new contributors getting their first PR ready.

This page is the short version. The fuller treatment of the repo’s conventions, CI gates, and Update Demand lives in the Internals section and in CLAUDE.md at the repository root.

Clone

git clone https://github.com/frankbardon/pulse.git
cd pulse

Tooling

Pulse needs only the Go toolchain — there is no Node, Python, or container build. Install the Go version go.mod names (its go and toolchain lines); with GOTOOLCHAIN=auto an older Go downloads it. Building the book (make docs) also needs mdBook 0.5.4.

The repo also uses staticcheck for make lint; it is auto-installed on first run via go run.

Common targets

CommandWhat it does
make buildBuilds the CLI binary to bin/pulse (default goal)
make testRuns the fast test tier and fails on any test of 1 s or more (The 1 s budget)
make test-heavyRuns go test -tags heavy ./...: both tiers, the //go:build heavy files included (Test tiers)
make fmtRuns gofmt -w .
make fmt-checkFails listing any Go file gofmt would rewrite
make vetRuns go vet ./..., then again with -tags heavy
make lintRuns fmt-check, vet, then staticcheck over both test tiers, merged (the CI lint job runs exactly this)
make coverRuns both tiers with coverage into coverage.out; fails on a package below its .github/coverage-floors.txt floor (Coverage floors)
make doc-checksRuns the fast documentation checks (Documentation Checks)
make cleanRemoves bin/, dist/ and the coverage profiles

A .env file at the repo root is auto-loaded and exported, so PULSE_DATA_DIR and any other PULSE_* env vars can live there for local development.

Run the binary you just built

make build
./bin/pulse --version
./bin/pulse --json | head -20

The CLI tree itself is mapped in the CLI Tour.

Where things live

The package layout is documented at Internals → Package Layout. Two pointers worth knowing on day one:

  • Public facade: pulse.go — the Pulse type and Options embedders start from.
  • CLI internals: internal/cli/ — one file per command group; never put processing logic here.

Read this before writing code