You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(cli): make smart-cli usable for automation — DI, rulesets, exit codes, batch init
Analyzed + fixed runtime defects that made the CLI unusable non-interactively.
- evaluate/drift no longer crash: thread IConfigParser + RulesetValidator through
the shared core-domain composition root (kind-evaluators, architecture-drift);
register ArchitectureDriftService as a provider and inject it.
- Self-contained rulesets: bundle <repo>/src/rulesets into the CLI package
(copy-rulesets.js, prebuild/prepublishOnly; gitignored — regenerated) + a
rulesets-resolver that resolves from the install (__dirname), --core/profile as
override, NEVER process.cwd(). Fixes topology-recommend/phase-artifacts ENOENT.
- Exit codes: BaseEvolithCommand.handleError + json error paths set exitCode=1
(nest-commander swallowed errors and exited 0).
- init non-interactive: --config <setup.json> or --name --yes (+ runtime/monorepo/
arch/db) run prompt-free; copy-assets.js ships config JSONs to dist so init
completes. scaffold guards a missing workspace (NOT_A_SATELLITE, exit 1) instead
of raw spawn ENOENT.
- test hygiene: mock the npm-registry version fetch (no network / WARN noise).
Build clean; 919 unit tests. Verified live from a scratch dir: evaluate/drift/
topology succeed with correct exit codes, and `init --name x --yes` scaffolds a
satellite non-interactively.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
0 commit comments