| author | |
| committer | |
| log | da2ba5b81f8be6afc6d54e728bf4ac8781f3ab1c |
| tree | 9f1cc754f8d1dbad274fb46d3e6e4bf432cf1f3b |
| parent | 1200f530bdc8be25ca1c85affa42b6d9c259601c |
| signature | Signed by PGP key B5690EEEBB952194 |
3 files changed, 9 insertions(+), 2 deletions(-)
docs/operations/development.md+4-1| ... | ... | @@ -72,10 +72,13 @@ Windows investigation while that suite is not a required gate. |
| 72 | 72 | ### Unused code |
| 73 | 73 | |
| 74 | 74 | `vp run knip:check` checks unused files and dependencies across the repo, then |
| 75 | unused runtime exports in every internal package under `packages/`. CI enforces both checks. | |
| 75 | unused runtime exports in `apps/web` and every internal package under `packages/`. | |
| 76 | CI enforces both checks. | |
| 76 | 77 | Exported types and Effect schemas are allowed without consumers. The schema preprocessor |
| 77 | 78 | recognizes schema types, including aliases and schema classes; functions that create or decode |
| 78 | 79 | schemas remain checked. Completely unused files remain checked too. |
| 80 | Named exports in web UI component modules are kept as complete component sets. Knip ignores | |
| 81 | unused exports in `apps/web/src/components/ui/*.tsx`, while still reporting an entire unused file. | |
| 79 | 82 | Use `vp run knip --workspace apps/web` to audit one workspace, including exports, |
| 80 | 83 | or `vp run knip:production --workspace apps/web` to find code kept alive only by tests. |
| 81 | 84 | The full export audit still has findings and is not a repo-wide CI gate. Extend the |
knip.jsonc+4| ... | ... | @@ -43,6 +43,10 @@ |
| 43 | 43 | "apps/web": { |
| 44 | 44 | // Worktree setup invokes this directly from t3.json. |
| 45 | 45 | "entry": ["scripts/warm-dep-cache.ts"], |
| 46 | // UI component modules are copied and adapted as cohesive sets. Keep their | |
| 47 | // named subcomponents even before they have callers; the file audit still | |
| 48 | // reports an entire component module when nothing imports it. | |
| 49 | "ignoreIssues": { "src/components/ui/*.tsx": ["exports", "nsExports", "duplicates"] }, | |
| 46 | 50 | }, |
| 47 | 51 | "apps/mobile": { |
| 48 | 52 | // Expo loads local config plugins by string; Metro handles platform variants. |
package.json+1-1| ... | ... | @@ -26,7 +26,7 @@ |
| 26 | 26 | "tc": "vp run -r --concurrency-limit 2 typecheck", |
| 27 | 27 | "lint": "vp lint --report-unused-disable-directives", |
| 28 | 28 | "knip": "knip --preprocessor ./scripts/knip-schemas.ts", |
| 29 | "knip:check": "knip --include files,dependencies --no-config-hints && knip --workspace packages/client-runtime --workspace packages/contracts --workspace packages/effect-acp --workspace packages/effect-codex-app-server --workspace packages/shared --workspace packages/ssh --workspace packages/tailscale --exports --preprocessor ./scripts/knip-schemas.ts --no-config-hints", | |
| 29 | "knip:check": "knip --include files,dependencies --no-config-hints && knip --workspace apps/web --workspace packages/client-runtime --workspace packages/contracts --workspace packages/effect-acp --workspace packages/effect-codex-app-server --workspace packages/shared --workspace packages/ssh --workspace packages/tailscale --exports --preprocessor ./scripts/knip-schemas.ts --no-config-hints", | |
| 30 | 30 | "knip:production": "knip --production --preprocessor ./scripts/knip-schemas.ts", |
| 31 | 31 | "lint:mobile": "node scripts/mobile-native-static-check.ts", |
| 32 | 32 | "test": "vp run -r test", |