# ExHarness
One-command installer for an opinionated Elixir/Phoenix static-analysis
suite, plus a `mix harness.init` whole-codebase audit (dialyzer + reach).
## Installation
```bash
mix igniter.install ex_harness
mix harness.install
mix deps.get
```
Skip individual tools with `--skip`:
```bash
mix harness.install --skip makeup,makeup_elixir
```
## Whole-codebase audit
```bash
mix harness.init # dialyzer + reach, output to .harness/
mix harness.init --skip dialyzer
mix harness.init --quick # reuse existing PLT
```
The audit writes `.harness/audit-<timestamp>.md` (and a `latest.md`
copy) summarising dialyzer findings, reach taints, and dead code.
## What gets installed
| Library | Role |
|---------|------|
| `credo` | Style / complexity / design lints |
| `dialyxir` | Success-typing analysis |
| `ex_dna` | Duplicate code detection |
| `ex_slop` | File naming / docstring lints |
| `boundary` | Compile-time module boundary enforcement |
| `reach` | Program Dependence Graph (taint / dead code) |
| `makeup` + `makeup_elixir` | Syntax highlighting for reach reports |
`mix harness.install` also:
- adds `:boundary` to the `compilers:` list,
- writes a `:dialyzer` config (`priv/plts/`),
- appends to (or creates) the `precommit` mix alias,
- creates `priv/plts/.gitkeep` and updates `.gitignore`,
- drops a default `.credo.exs` if none exists.
## After installing
1. `mix deps.get`
2. `mix dialyzer --plt` (one-time PLT build, 30–60s)
3. Add `use Boundary` to each top-level context — see the
[boundary docs](https://hexdocs.pm/boundary).
4. `mix harness.init` for the first audit.
## License
MIT