docs format with ocamlformat, not dune fmt, under watch builds

dune fmt connects to the Dune RPC server the watch process owns, so its connection drops mid-rebuild and looks like a build failure. Direct ocamlformat --inplace avoids the shared server. Also route the done-check commands through --build-dir _build-agent.

Commit
f2dad7110d358f21a2a8d31bd4912102d19e883c
Author
Marius Peter <dev@marius-peter.com>
Author date
Committer
Marius Peter <dev@marius-peter.com>
Committer date
.kiro/steering/workflow.md
index 77f39348..0feaac90 100644..100644
@@ -4,10 +4,14 @@
4 4
5 5 A feature is not finished until, in this order:
6 6
7 Removed: 1. `dune build @check` is clean (type-checks library *and* tests).
7 Added: 1. `dune build @check --build-dir _build-agent` is clean (type-checks library
8 Added: *and* tests).
8 9 2. Alcotests exist for it — unit tests for behaviour, end-to-end tests for flows
9 Removed: that cross module boundaries — and `dune runtest` passes.
10 Removed: 3. `dune fmt` has been run and `dune build @fmt` is clean.
10 Added: that cross module boundaries — and `dune runtest --build-dir _build-agent`
11 Added: passes.
12 Added: 3. Formatting is applied and `dune build @fmt --build-dir _build-agent` is
13 Added: clean. Format with `ocamlformat --inplace` on the touched files, never
14 Added: `dune fmt` (see Build directory safety).
11 15 4. Documentation reflects the change.
12 16
13 17 Then, and only then:
@@ -57,3 +61,16 @@
57 61 - `dune runtest --build-dir _build-agent`
58 62
59 63 Do not run `dune clean` on the default `_build` directory.
64 Added:
65 Added: Never run `dune fmt` while a watch build runs. `dune fmt` ignores
66 Added: `--build-dir` and connects to the Dune RPC server that the watch process owns.
67 Added: That connection is dropped mid-rebuild, and the failure looks like a build
68 Added: error when the code is fine.
69 Added:
70 Added: Format with `ocamlformat` directly, which does not touch the RPC server:
71 Added:
72 Added: - `ocamlformat --inplace <files you changed>`
73 Added:
74 Added: Then confirm with `dune build @fmt --build-dir _build-agent`, which uses the
75 Added: isolated build directory. Do not chain formatting after passing steps with
76 Added: `&&`. A dropped format connection must not mask a clean build and test run.