CodeVetter · Repo Unpack · System map
nrwl/nx
The principal product boundary is the installed Nx CLI, with TypeScript orchestration and Rust native services. Project discovery and hashing can run through a daemon or inside the invoking process. Artifact storage, database state, executor processes, and browser visualization have distinct ownership boundaries. Distribution includes npm packages and platform binaries, while documentation is a separate Astro application.
- The published nx package exposes nx and nx-cloud binaries under dist/bin and distributes command implementations, schemas, executor registries, and generator registries.
- bin/nx.ts owns platform checks, workspace discovery, environment initialization, local installation resolution, and delegation; initLocal routes arguments into the shared Yargs commandsObject.
- The Cargo workspace contains packages/nx; its npm manifest declares N-API binaries for Linux, macOS, Windows, and FreeBSD, and native/index.js intercepts loading of Nx native modules.
- createProjectGraphAsync chooses cached graph reuse or createProjectGraphAndSourceMapsAsync; the latter requests daemon state when enabled and otherwise coordinates construction with a file lock.
- runCommand wraps execution with plugin hooks; defaultTasksRunner creates TaskOrchestrator, which owns scheduling, cache access, executor process runners, and continuous-task state.
- Native NxCache indexes artifacts through a database connection; getDbConnection uses shared workspace data, while getLocalDbConnection explicitly scopes running-task state to a worktree.
- The browser graph has React Router project, task, and project-details surfaces; Astro documentation uses Starlight, Markdoc, React, and Netlify, with plugin references generated from package metadata.
- Root scripts define pnpm-driven build, test, e2e, and local-registry workflows; native builds use @monodon/rust:napi, and release publication runs in the npm-registry GitHub environment after native build jobs.