|
1 | | -# AGENTS.md |
| 1 | +# healthd |
2 | 2 |
|
3 | | -Project instructions for coding agents in `healthd`. |
| 3 | +Local host health-check daemon. Runs checks, alerts on transitions. See `docs/ARCHITECTURE.md`. |
4 | 4 |
|
5 | 5 | ## Stack |
6 | | -- Language: Go |
7 | | -- CLI: Cobra |
8 | | -- Config: TOML (strict parsing + validation) |
| 6 | +- Go 1.24, Cobra CLI, TOML config |
| 7 | +- TUI: charmbracelet/bubbletea + lipgloss |
| 8 | +- Notifications: ntfy, command backends |
9 | 9 |
|
10 | | -## Workflow |
11 | | -- Build in small vertical slices aligned to issues. |
12 | | -- Prefer stacked PRs with Graphite for dependent work. |
13 | | -- Keep behavior deterministic; avoid hidden magic. |
14 | | - |
15 | | -## Quality Gate (must pass before commit) |
| 10 | +## Commands |
| 11 | +```bash |
| 12 | +go build ./... # build |
| 13 | +go test ./... # all tests |
| 14 | +go vet ./... # lint |
| 15 | +go test -cover ./... # coverage (80% gate) |
| 16 | +make install # build → ~/.local/bin/healthd |
| 17 | +scripts/release.sh vX.Y.Z # full release + brew update |
| 18 | +``` |
16 | 19 |
|
| 20 | +## Running |
17 | 21 | ```bash |
18 | | -go fmt ./... |
19 | | -go test ./... |
| 22 | +healthd check --config ~/.config/healthd/config.toml # one-shot |
| 23 | +healthd status --config ~/.config/healthd/config.toml # TUI |
| 24 | +healthd status --config ~/.config/healthd/config.toml -w # live dashboard |
| 25 | +healthd daemon install --config ~/.config/healthd/config.toml # launchd |
20 | 26 | ``` |
21 | 27 |
|
22 | | -When linters are added, include them in the gate. |
| 28 | +## Paths |
| 29 | +- **Binary:** `~/.local/bin/healthd` |
| 30 | +- **Config:** `~/.config/healthd/config.toml` |
| 31 | +- **State:** `~/.local/state/healthd/` (alerts.log) |
| 32 | +- **LaunchAgent:** `com.uinaf.healthd` |
23 | 33 |
|
24 | 34 | ## Conventions |
25 | | -- Keep packages focused and testable. |
26 | | -- Parse config into typed structs; reject unknown keys. |
27 | | -- No auto-remediation in v1 (detect/report only). |
28 | | -- Do not add unrelated changes in the same branch. |
| 35 | +- Build in small vertical slices aligned to issues |
| 36 | +- Prefer stacked PRs with Graphite for dependent work |
| 37 | +- Parse config into typed structs; reject unknown keys |
| 38 | +- No auto-remediation in v1 (detect/report only) |
| 39 | +- Keep packages focused and testable |
| 40 | +- Do not add unrelated changes in the same branch |
0 commit comments