Skip to content

Build & Test

codexclaw builds and tests with the Node.js built-in toolchain only. There is no bundler, no tsc, and no network step, so the build is reproducible and idempotent.

Terminal window
npm run build

This compiles each component’s src/*.ts to dist/*.js using Node’s built-in type stripping and a small resolver fix so bare specifiers resolve at the shipped dist path. Re-running produces the same output (idempotent).

Terminal window
npm test

The root test script runs node --test across every component’s test directory plus the GUI and plugin integration tests:

  • pabcd-state
  • config-guard
  • cxc-ops
  • provider-bridge
  • subagent-config
  • gui
  • plugin integration (plugins/codexclaw/test/*.test.mjs)

A change is not complete until npm run build and npm test both pass. The C → D PABCD transition records the test tail and a zero exit code as evidence — see the PABCD Workflow.

Use Node.js 22+. The build relies on built-in TypeScript type stripping, and the hooks and CLI run under node directly.