# `mix adr.cites`
[🔗](https://github.com/riddler/statifier_blocks/blob/v0.44.1/lib/mix/tasks/adr.cites.ex#L1)

Reports citations into `docs/adr/` that no longer point at the text they were
written against.

Records cite each other by path and line - `docs/adr/0002-...md:4108`, then
`` `:4121-4122` `` for the same file - and the plans and `CLAUDE.md` cite the
records the same way. An insert or a re-wrap above a cited line moves it, and
the citing document, untouched on `main`, silently points at different text.
This task is the check for that; the reasoning, the documents it scans and
the three layers it runs are in `Mix.StatifierBlocks.AdrCites`.

It runs as the `ADR cites` custom stage of `mix quality`, so the drift is a
named gate failure rather than something review has to catch.

## Usage

    mix adr.cites
    mix adr.cites --format json
    mix adr.cites --update

## Options

  * `--format json` - print the ExQuality finding contract instead of prose
  * `--update` - rewrite `docs/adr/.cite-baseline.json` from the current tree

`--update` is what a request that legitimately moves a cited line runs, in
that same request, so the move is reviewed as a diff of the recorded text
rather than discovered by the next record to be edited.

Exit status is 0 when nothing failed and 1 when something did. Advisory
findings - an unanchored paragraph, a citation the baseline has not yet seen
- are reported and do not change the status.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
