diff --git a/AGENTS.md b/AGENTS.md index a0ff5c2..6d89068 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -64,12 +64,20 @@ real-phone/WireGuard bring-up, which is operational rather than code. ## Checking your work -- Server: `./run-tests.sh` (or `cargo test`) + `cargo clippy --all-targets` - from `server/` — the build stays warning-clean, keep it that way. -- App: from `app/`, `. ./android-env.sh && ./gradlew :androidApp:compileDebugKotlin` - to typecheck; `./build-apk.sh` to produce the APK to install on a phone - (through Dev Updater); `./run-android.sh` to build, install, and launch - on the emulator. +- Server: from `server/`, `./run-tests.sh` (or `cargo test`) + + `cargo clippy --all-targets` + `cargo fmt`. The build stays + warning-clean and rustfmt-clean at the defaults — there is no + `rustfmt.toml` and there should not be one. +- App: from `app/`, `. ./android-env.sh && ./gradlew :androidApp:ktfmtFormat + :androidApp:compileDebugKotlin :androidApp:lintDebug` — format, typecheck + and lint, the app-side equivalent of the line above. Then `./build-apk.sh` + to produce the APK to install on a phone (through Dev Updater), or + `./run-android.sh` to build, install, and launch on the emulator. +- **Android Lint is not optional and is not run by a build.** It found a + crash that had been shipping: `java.time` on a minSdk-24 app with + desugaring off. It is clean now apart from Compose 1.11.1 having a 1.12.0 + available; keep it that way, and suppress with `tools:ignore` plus a + written reason rather than by lowering the bar. - **The APK pins the CA of the machine that builds it**, read at build time from `$XDG_CONFIG_HOME/ai-app/certs/ca.pem` (`AI_APP_CA` overrides) and generated into a constant. So the server must have started once on that