/** * Doctor subcommand — diagnostic-only self-check for ContextAtlas * configuration + state. * * Per v0.4 Step 8 design (STEP-PLAN-V0.4.md). Five check categories * (config + atlas + sha + lsp + extraction); per-language LSP * gating via `config.languages`; limited mode (no `.contextatlas.yml`) * runs filesystem checks only. * * Per ADR-12 subcommand-vs-flag partition: doctor is its own * subcommand path, not a flag on the default mcp invocation. * * Full developer-onboarding pipeline (auto-fix; guided extraction) * is v0.5+ scope. */ import type { DoctorResult } from "./types.js"; export interface DoctorRunOptions { /** Repo root the doctor inspects. Defaults to `process.cwd()`. */ readonly repoRoot?: string; /** When true, emit JSON-formatted output to stdout instead of text. */ readonly json?: boolean; /** Test seam: override stdout writer (default `process.stdout.write`). */ readonly writeStdout?: (chunk: string) => void; } export interface DoctorRunResult { readonly exitCode: number; } /** * Run the doctor subcommand. Reads optional `.contextatlas.yml`, * dispatches to per-category checks, formats output per `--json` * flag, returns the appropriate exit code. * * Limited mode (no config) emits a top-level WARN and runs only * filesystem-level extraction-prerequisite checks. */ export declare function runDoctorSubcommand(options?: DoctorRunOptions): Promise; export interface CollectChecksOptions { /** * True when invoked from `init`'s first-run gate-check per v0.7 * Step 2.2.d FO-7 fix (Option iii hybrid). First-run state implies: * * - Atlas substantively NOT YET extracted (so `atlas.exists` FAIL * would be a false-positive — it's the expected pre-extraction * state, not a broken-post-extraction state) * * When `firstRun === true`, atlas-related checks are downgraded: * * - `atlas.exists` FAIL → WARN with first-run-aware message * - Other atlas.* checks gated on atlas.exists pass (so they * surface only when atlas substantively exists) * * Subsequent doctor invocations (standalone `contextatlas doctor`; * NOT from init) preserve the original FAIL semantics — at that * point atlas absent IS a broken-post-extraction state worth * surfacing. */ readonly firstRun?: boolean; } /** * Run the full check set, gated by config presence. Exposed for * direct unit testing (the orchestrator can be invoked without the * stdout-writing wrapper). */ export declare function collectChecks(repoRoot: string, options?: CollectChecksOptions): Promise; //# sourceMappingURL=runner.d.ts.map