@geoql/nuxt-doctor 0.1.1 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -101,7 +101,7 @@ Nuxt 4 only: the `app/` directory layout with `compatibilityVersion: 4`. For a p
101
101
 
102
102
  ## Architecture
103
103
 
104
- See [`docs/ARCHITECTURE.md`](../../docs/ARCHITECTURE.md).
104
+ See [`docs/SPEC.md`](../../docs/SPEC.md) §10.
105
105
 
106
106
  ## License
107
107
 
package/dist/index.js CHANGED
@@ -2,8 +2,9 @@ import { readFileSync, writeFileSync } from "node:fs";
2
2
  import { dirname, resolve } from "node:path";
3
3
  import process from "node:process";
4
4
  import { fileURLToPath } from "node:url";
5
- import { audit, detectProject, encodeAnnotations, format, listChangedFiles, listRules, loadDoctorConfig, loadRuleDoc, mergeCliOverrides, renderVerboseTrace } from "@geoql/doctor-core";
5
+ import { audit, detectProject, detectSummary, encodeAnnotations, findMonorepoRoot, format, listChangedFiles, listRules, listWorkspacePackages, loadDoctorConfig, loadRuleDoc, mergeCliOverrides, normalizeInitAnswers, planInit, renderVerboseTrace, scoreDiagnostics } from "@geoql/doctor-core";
6
6
  import { cac } from "cac";
7
+ import prompts from "prompts";
7
8
  //#region src/cli.ts
8
9
  function readVersion() {
9
10
  try {
@@ -41,7 +42,7 @@ function renderInspect(p, rootDir) {
41
42
  lines.push("");
42
43
  lines.push("framework");
43
44
  lines.push(` ${p.framework}`);
44
- lines.push(` vue: ${p.vueVersion ?? "(none)"}`);
45
+ lines.push(` nuxt: ${p.nuxtVersion ?? "(none)"}`);
45
46
  lines.push(` typescript: ${p.typescriptVersion ?? "(none)"}`);
46
47
  lines.push("");
47
48
  lines.push("project layout");
@@ -101,6 +102,11 @@ const VALID_SOURCES = new Set([
101
102
  "oxlint-builtin",
102
103
  "eslint-plugin-vue"
103
104
  ]);
105
+ const VALID_CONFIG_FORMATS = new Set([
106
+ "ts",
107
+ "json",
108
+ "package-json"
109
+ ]);
104
110
  function buildListRulesFilter(flags) {
105
111
  const out = {};
106
112
  if (flags.preset !== void 0) {
@@ -152,19 +158,253 @@ function parseRuleOverrides(rules) {
152
158
  return out;
153
159
  }
154
160
  function resolveFormat(flags) {
161
+ if (flags.prComment !== void 0) return "pr-comment";
155
162
  if (flags.jsonCompact) return "json-compact";
156
163
  if (flags.json) return "json";
157
164
  const kind = flags.format;
158
- if (kind === "pretty" || kind === "json" || kind === "json-compact" || kind === "sarif" || kind === "html") return kind;
165
+ if (kind === "pretty" || kind === "json" || kind === "json-compact" || kind === "sarif" || kind === "html" || kind === "pr-comment") return kind;
159
166
  if (typeof flags.output === "string" && flags.output.toLowerCase().endsWith(".html")) return "html";
160
167
  return "agent";
161
168
  }
162
169
  function isFailOnLevel(v) {
163
170
  return v === "error" || v === "warn" || v === "none";
164
171
  }
172
+ async function runSingleAudit(rootDir, flags, prepared) {
173
+ let scopeFiles;
174
+ if (!flags.full && (flags.diff || flags.staged)) scopeFiles = await listChangedFiles({
175
+ rootDir,
176
+ mode: flags.staged ? "staged" : "diff"
177
+ });
178
+ const resolved = await loadDoctorConfig(rootDir, {
179
+ ...flags.config ? { explicitPath: flags.config } : {},
180
+ ...flags.preset ? { presetOverride: flags.preset } : {}
181
+ });
182
+ const fixExclude = toArray(flags.fixExclude);
183
+ const merged = mergeCliOverrides(resolved, {
184
+ failOn: flags.failOn,
185
+ include: toArray(flags.include),
186
+ exclude: toArray(flags.exclude),
187
+ rules: prepared.ruleOverrides,
188
+ threshold: prepared.threshold,
189
+ ...fixExclude ? { fixExcludes: fixExclude } : {}
190
+ });
191
+ const report = await audit({
192
+ rootDir: merged.rootDir,
193
+ include: merged.include,
194
+ exclude: merged.exclude,
195
+ rules: merged.rules,
196
+ failOn: merged.failOn,
197
+ threshold: merged.threshold,
198
+ deadCode: flags.deadCode,
199
+ lint: flags.lint,
200
+ respectInlineDisables: flags.respectInlineDisables,
201
+ scopeFiles,
202
+ fix: flags.fix,
203
+ ...merged.fixExcludes ? { fixExcludes: merged.fixExcludes } : {}
204
+ });
205
+ const allowedRuleIds = new Set(Object.keys(merged.rules));
206
+ report.diagnostics = report.diagnostics.filter((d) => allowedRuleIds.has(d.ruleId));
207
+ return {
208
+ report,
209
+ source: resolved.source
210
+ };
211
+ }
212
+ function aggregateReports(reports, rootDirectory) {
213
+ const first = reports[0];
214
+ const diagnostics = reports.flatMap((r) => r.diagnostics);
215
+ let filesScanned = 0;
216
+ let elapsedMs = 0;
217
+ let exitCode = 0;
218
+ for (const r of reports) {
219
+ filesScanned += r.filesScanned;
220
+ elapsedMs += r.elapsedMs;
221
+ if (r.exitCode > exitCode) exitCode = r.exitCode;
222
+ }
223
+ const ruleCounts = {};
224
+ for (const d of diagnostics) ruleCounts[d.ruleId] = (ruleCounts[d.ruleId] ?? 0) + 1;
225
+ const scoreResult = scoreDiagnostics(diagnostics, { threshold: first.scoreResult.threshold });
226
+ return {
227
+ rootDir: rootDirectory,
228
+ filesScanned,
229
+ diagnostics,
230
+ score: scoreResult.score,
231
+ errorCount: scoreResult.errorCount,
232
+ warnCount: scoreResult.warnCount,
233
+ infoCount: scoreResult.infoCount,
234
+ exitCode,
235
+ scoreResult,
236
+ projectInfo: {
237
+ ...first.projectInfo,
238
+ rootDirectory
239
+ },
240
+ elapsedMs,
241
+ timings: first.timings,
242
+ ruleCounts
243
+ };
244
+ }
245
+ function emitReport(report, reporter, flags) {
246
+ const out = format({
247
+ toolName: "@geoql/nuxt-doctor",
248
+ toolVersion: readVersion(),
249
+ rootDirectory: report.rootDir,
250
+ analyzedFileCount: report.filesScanned,
251
+ elapsedMs: report.elapsedMs,
252
+ diagnostics: report.diagnostics,
253
+ score: report.scoreResult,
254
+ projectInfo: report.projectInfo
255
+ }, reporter, {
256
+ color: flags.color,
257
+ quiet: flags.quiet
258
+ });
259
+ if (flags.output) writeFileSync(resolve(flags.output), out);
260
+ else process.stdout.write(out);
261
+ const ciExplicitOptOut = flags.ci === false;
262
+ const ciExplicitOptIn = flags.ci === true;
263
+ const ciAutoDetected = !ciExplicitOptOut && isCiEnvironment();
264
+ if ((flags.annotations === true || ciExplicitOptIn || ciAutoDetected) && (reporter === "agent" || reporter === "pretty") && !flags.quiet && report.diagnostics.length > 0) process.stdout.write(`${encodeAnnotations(report.diagnostics)}\n`);
265
+ }
266
+ async function runProjectAudits(rootDir, flags, prepared, packages) {
267
+ const requested = flags.project.split(",").map((name) => name.trim()).filter((name) => name.length > 0);
268
+ const byName = new Map(packages.map((p) => [p.name, p]));
269
+ const reports = [];
270
+ let source = "built-in";
271
+ for (const name of requested) {
272
+ const match = byName.get(name);
273
+ if (!match) {
274
+ process.stderr.write(`nuxt-doctor: --project: unknown project "${name}" (skipped)\n`);
275
+ continue;
276
+ }
277
+ const single = await runSingleAudit(match.dir, flags, prepared);
278
+ reports.push(single.report);
279
+ source = single.source;
280
+ }
281
+ if (reports.length === 0) {
282
+ process.stderr.write("nuxt-doctor: --project: no matching workspace projects\n");
283
+ return null;
284
+ }
285
+ const { root } = await findMonorepoRoot(rootDir);
286
+ return {
287
+ report: aggregateReports(reports, root),
288
+ source
289
+ };
290
+ }
291
+ async function runInit(dir, flags) {
292
+ const targetDir = resolve(dir);
293
+ const configFormat = flags.configFormat ?? "ts";
294
+ if (!VALID_CONFIG_FORMATS.has(configFormat)) {
295
+ process.stderr.write(`nuxt-doctor init: --config-format must be ts | json | package-json, got '${flags.configFormat}'\n`);
296
+ process.exitCode = 2;
297
+ return;
298
+ }
299
+ const resolvedAnswers = flags.yes ? {
300
+ configFormat,
301
+ preset: "recommended",
302
+ threshold: void 0,
303
+ exclude: void 0
304
+ } : await runInteractiveInit(configFormat);
305
+ if (process.exitCode === 2) return;
306
+ const plan = await planInit({
307
+ dir: targetDir,
308
+ configFormat: resolvedAnswers.configFormat,
309
+ preset: resolvedAnswers.preset,
310
+ threshold: resolvedAnswers.threshold,
311
+ exclude: resolvedAnswers.exclude,
312
+ binName: "nuxt-doctor"
313
+ });
314
+ const summary = await detectSummary(targetDir);
315
+ process.stdout.write(`${summary}\n`);
316
+ if (plan.conflict && !flags.force) {
317
+ process.stderr.write(`nuxt-doctor init: ${plan.conflictPath} already exists. Run with --force to overwrite.\n`);
318
+ process.exitCode = 2;
319
+ return;
320
+ }
321
+ if (flags.dryRun) {
322
+ for (const write of plan.writes) {
323
+ process.stdout.write(`[dry-run] would write ${write.path}\n`);
324
+ process.stdout.write(`${write.content}\n`);
325
+ }
326
+ process.exitCode = 0;
327
+ return;
328
+ }
329
+ for (const write of plan.writes) writeFileSync(write.path, write.content, "utf8");
330
+ process.exitCode = 0;
331
+ }
332
+ async function runInteractiveInit(defaultFormat) {
333
+ const answers = await prompts([
334
+ {
335
+ type: "select",
336
+ name: "target",
337
+ message: "Config target?",
338
+ choices: [
339
+ {
340
+ title: "doctor.config.ts (recommended)",
341
+ value: "ts"
342
+ },
343
+ {
344
+ title: "doctor.config.json",
345
+ value: "json"
346
+ },
347
+ {
348
+ title: "package.json#doctor",
349
+ value: "package-json"
350
+ }
351
+ ],
352
+ initial: defaultFormat === "package-json" ? 2 : 0
353
+ },
354
+ {
355
+ type: "select",
356
+ name: "preset",
357
+ message: "Base preset?",
358
+ choices: [
359
+ {
360
+ title: "recommended (errors + warnings)",
361
+ value: "recommended"
362
+ },
363
+ {
364
+ title: "strict (recommended + info)",
365
+ value: "strict"
366
+ },
367
+ {
368
+ title: "minimal (errors only)",
369
+ value: "minimal"
370
+ }
371
+ ],
372
+ initial: 0
373
+ },
374
+ {
375
+ type: "number",
376
+ name: "threshold",
377
+ message: "Minimum passing score (0-100, blank to skip)",
378
+ min: 0,
379
+ max: 100,
380
+ initial: ""
381
+ },
382
+ {
383
+ type: "text",
384
+ name: "exclude",
385
+ message: "Exclude glob patterns (comma-separated, blank to skip)",
386
+ initial: ""
387
+ }
388
+ ], { onCancel: () => {
389
+ process.stderr.write("nuxt-doctor init: cancelled\n");
390
+ process.exitCode = 2;
391
+ } });
392
+ if (process.exitCode === 2) return {
393
+ configFormat: "ts",
394
+ preset: "recommended",
395
+ threshold: void 0,
396
+ exclude: void 0
397
+ };
398
+ return normalizeInitAnswers({
399
+ target: answers.target,
400
+ preset: answers.preset,
401
+ threshold: answers.threshold || void 0,
402
+ exclude: answers.exclude
403
+ });
404
+ }
165
405
  async function run(argv = process.argv) {
166
406
  const cli = cac("nuxt-doctor");
167
- cli.command("[path]", "Audit a Nuxt project").option("--format <kind>", "Output format (agent|pretty|json|json-compact|sarif|html)", { default: "agent" }).option("--json", "Shorthand for --format json").option("--json-compact", "Emit single-line JSON").option("--config <path>", "Path to doctor.config.ts").option("--preset <name>", "Base preset: minimal|recommended|strict|all").option("--fail-on <level>", "Exit non-zero on this severity or worse (error|warn|none)", { default: "error" }).option("--quiet", "Only show the summary").option("--verbose", "Emit per-pass timing and rule diagnostics to stderr").option("--no-color", "Disable colored output").option("--rule <id:level>", "Override a rule (repeatable), e.g. --rule a/b:off").option("--include <glob>", "Glob of files to include (repeatable)").option("--exclude <glob>", "Glob of files to exclude (repeatable)").option("--no-dead-code", "Skip the dead-code (knip) analysis pass").option("--no-lint", "Skip the lint passes (template/SFC/oxlint)").option("--no-respect-inline-disables", "Surface findings even inside doctor-disable comments").option("--threshold <n>", "Minimum passing score (0-100)").option("--score", "Output only the numeric score (for piping)").option("--annotations", "Emit GitHub Actions ::error::/::warning:: lines").option("--ci", "Auto-enable CI behavior (--annotations on GitHub Actions)").option("--no-ci", "Disable CI auto-detection even when CI env is set").option("--diff", "Only report findings in files changed vs HEAD").option("--staged", "Only report findings in staged files").option("--full", "Force a complete scan (overrides --diff/--staged)").option("--output <file>", "Write the report to a file instead of stdout").action(async (path, flags) => {
407
+ cli.command("[path]", "Audit a Nuxt project").option("--format <kind>", "Output format (agent|pretty|json|json-compact|sarif|html|pr-comment)", { default: "agent" }).option("--json", "Shorthand for --format json").option("--json-compact", "Emit single-line JSON").option("--config <path>", "Path to doctor.config.ts").option("--preset <name>", "Base preset: minimal|recommended|strict|all").option("--fail-on <level>", "Exit non-zero on this severity or worse (error|warn|none)", { default: "error" }).option("--quiet", "Only show the summary").option("--verbose", "Emit per-pass timing and rule diagnostics to stderr").option("--no-color", "Disable colored output").option("--rule <id:level>", "Override a rule (repeatable), e.g. --rule a/b:off").option("--include <glob>", "Glob of files to include (repeatable)").option("--exclude <glob>", "Glob of files to exclude (repeatable)").option("--no-dead-code", "Skip the dead-code (knip) analysis pass").option("--no-lint", "Skip the lint passes (template/SFC/oxlint)").option("--no-respect-inline-disables", "Surface findings even inside doctor-disable comments").option("--threshold <n>", "Minimum passing score (0-100)").option("--score", "Output only the numeric score (for piping)").option("--annotations", "Emit GitHub Actions ::error::/::warning:: lines").option("--ci", "Auto-enable CI behavior (--annotations on GitHub Actions)").option("--no-ci", "Disable CI auto-detection even when CI env is set").option("--diff", "Only report findings in files changed vs HEAD").option("--staged", "Only report findings in staged files").option("--full", "Force a complete scan (overrides --diff/--staged)").option("--project <name>", "Comma-separated workspace project names to audit (monorepo)").option("--output <file>", "Write the report to a file instead of stdout").option("--pr-comment", "Emit a focused Markdown PR-comment body").option("--fix", "Auto-fix oxlint-pass findings in place (built-in vue/* rules only; template/SFC/dead-code/project findings are not fixable). Skipped in --diff/--staged mode.").option("--fix-exclude <ruleId>", "Mark a rule as not-auto-fixable (repeatable). Note: oxlint applies built-in fixes globally, so this is enforced only for doctor plugin fixes; built-in vue/* fixes still apply.").action(async (path, flags) => {
168
408
  const reporter = resolveFormat(flags);
169
409
  if (flags.failOn !== void 0 && !isFailOnLevel(flags.failOn)) {
170
410
  process.stderr.write(`nuxt-doctor: --fail-on must be 'error', 'warn', or 'none', got '${flags.failOn}'\n`);
@@ -178,65 +418,43 @@ async function run(argv = process.argv) {
178
418
  const threshold = flags.threshold === void 0 ? void 0 : Number(flags.threshold);
179
419
  if (threshold !== void 0 && (!Number.isInteger(threshold) || threshold < 0 || threshold > 100)) throw new Error(`--threshold must be an integer 0-100, got "${flags.threshold}".`);
180
420
  if (flags.diff && flags.staged) throw new Error("--diff and --staged are mutually exclusive.");
181
- if (flags.verbose && flags.quiet) throw new Error("--verbose and --quiet are mutually exclusive.");
182
- let scopeFiles;
183
- if (!flags.full && (flags.diff || flags.staged)) scopeFiles = await listChangedFiles({
184
- rootDir,
185
- mode: flags.staged ? "staged" : "diff"
186
- });
187
- const resolved = await loadDoctorConfig(rootDir, {
188
- ...flags.config ? { explicitPath: flags.config } : {},
189
- ...flags.preset ? { presetOverride: flags.preset } : {}
190
- });
191
- const merged = mergeCliOverrides(resolved, {
192
- failOn: flags.failOn,
193
- include: toArray(flags.include),
194
- exclude: toArray(flags.exclude),
195
- rules: ruleOverrides,
421
+ if (flags.verbose && flags.quiet) throw new Error("--verbose using --quiet are mutually exclusive.");
422
+ const fixActive = flags.fix === true;
423
+ const fixSkippedForScope = fixActive && !flags.full && (flags.diff || flags.staged);
424
+ if (fixSkippedForScope) process.stderr.write("nuxt-doctor: --fix skipped in --diff/--staged mode (auto-fix only runs on a full scan to avoid rewriting files outside the diff).\n");
425
+ if (fixActive && flags.fixExclude !== void 0) process.stderr.write("nuxt-doctor: --fix-exclude is not enforced for built-in vue/* rules (oxlint applies their fixes globally); it currently scopes only future doctor plugin fixes.\n");
426
+ const prepared = {
427
+ ruleOverrides,
196
428
  threshold
197
- });
198
- const report = await audit({
199
- rootDir: merged.rootDir,
200
- include: merged.include,
201
- exclude: merged.exclude,
202
- rules: merged.rules,
203
- failOn: merged.failOn,
204
- threshold: merged.threshold,
205
- deadCode: flags.deadCode,
206
- lint: flags.lint,
207
- respectInlineDisables: flags.respectInlineDisables,
208
- scopeFiles
209
- });
210
- const allowedRuleIds = new Set(Object.keys(merged.rules));
211
- report.diagnostics = report.diagnostics.filter((d) => allowedRuleIds.has(d.ruleId));
429
+ };
430
+ const workspacePackages = flags.project ? await listWorkspacePackages(rootDir) : [];
431
+ if (flags.project && workspacePackages.length === 0) process.stderr.write("nuxt-doctor: --project ignored: not a pnpm workspace\n");
432
+ let report;
433
+ let configSource;
434
+ if (flags.project && workspacePackages.length > 0) {
435
+ const aggregated = await runProjectAudits(rootDir, flags, prepared, workspacePackages);
436
+ if (!aggregated) {
437
+ process.exitCode = 2;
438
+ return;
439
+ }
440
+ report = aggregated.report;
441
+ configSource = aggregated.source;
442
+ } else {
443
+ const single = await runSingleAudit(rootDir, flags, prepared);
444
+ report = single.report;
445
+ configSource = single.source;
446
+ }
212
447
  if (flags.verbose) {
213
- const verboseOutput = renderVerboseTrace(report, { configSource: resolved.source });
448
+ const verboseOutput = renderVerboseTrace(report, { configSource });
214
449
  process.stderr.write(`${verboseOutput}\n`);
215
450
  }
451
+ if (fixActive && !fixSkippedForScope) process.stderr.write(`nuxt-doctor: applied oxlint --fix; ${report.diagnostics.length} finding${report.diagnostics.length === 1 ? "" : "s"} remain (re-run to see them).\n`);
216
452
  if (flags.score) {
217
453
  process.stdout.write(`${report.score}\n`);
218
454
  process.exitCode = report.exitCode;
219
455
  return;
220
456
  }
221
- const out = format({
222
- toolName: "@geoql/nuxt-doctor",
223
- toolVersion: readVersion(),
224
- rootDirectory: report.rootDir,
225
- analyzedFileCount: report.filesScanned,
226
- elapsedMs: report.elapsedMs,
227
- diagnostics: report.diagnostics,
228
- score: report.scoreResult,
229
- projectInfo: report.projectInfo
230
- }, reporter, {
231
- color: flags.color,
232
- quiet: flags.quiet
233
- });
234
- if (flags.output) writeFileSync(resolve(flags.output), out);
235
- else process.stdout.write(out);
236
- const ciExplicitOptOut = flags.ci === false;
237
- const ciExplicitOptIn = flags.ci === true;
238
- const ciAutoDetected = !ciExplicitOptOut && isCiEnvironment();
239
- if ((flags.annotations === true || ciExplicitOptIn || ciAutoDetected) && (reporter === "agent" || reporter === "pretty") && !flags.quiet && report.diagnostics.length > 0) process.stdout.write(`${encodeAnnotations(report.diagnostics)}\n`);
457
+ emitReport(report, reporter, flags);
240
458
  process.exitCode = report.exitCode;
241
459
  } catch (err) {
242
460
  const msg = err instanceof Error ? err.message : String(err);
@@ -282,6 +500,14 @@ async function run(argv = process.argv) {
282
500
  } else process.stdout.write(renderInspect(project, rootDir));
283
501
  process.exitCode = 0;
284
502
  });
503
+ cli.command("init [dir]", "Scaffold a doctor config for the project").option("-y, --yes", "Non-interactive, use recommended defaults").option("--config-format <ts|json|package-json>", "Config file format (default: ts)").option("--force", "Overwrite existing config").option("--dry-run", "Print what would be written, touch nothing").action(async (dir, flags) => {
504
+ try {
505
+ await runInit(dir ?? ".", flags);
506
+ } catch (err) {
507
+ process.stderr.write(`${err instanceof Error ? err.message : err}\n`);
508
+ process.exitCode = 2;
509
+ }
510
+ });
285
511
  cli.help();
286
512
  cli.version(readVersion());
287
513
  cli.parse(argv, { run: false });
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../src/cli.ts"],"sourcesContent":["import { readFileSync, writeFileSync } from 'node:fs';\nimport { dirname, resolve } from 'node:path';\nimport process from 'node:process';\nimport { fileURLToPath } from 'node:url';\nimport {\n audit,\n detectProject,\n encodeAnnotations,\n format,\n listChangedFiles,\n listRules,\n loadDoctorConfig,\n loadRuleDoc,\n mergeCliOverrides,\n renderVerboseTrace,\n type ListRulesFilter,\n type ProjectInfo,\n type RegisteredRule,\n type ReporterFormat,\n type ReporterInput,\n type RuleCategory,\n type RuleSource,\n type Severity,\n} from '@geoql/doctor-core';\nimport { cac } from 'cac';\n\nfunction readVersion(): string {\n try {\n const here = dirname(fileURLToPath(import.meta.url));\n const pkg = JSON.parse(\n readFileSync(resolve(here, '../package.json'), 'utf-8'),\n ) as { version?: string };\n return pkg.version ?? '0.0.0';\n } catch {\n return '0.0.0';\n }\n}\n\ninterface ListRulesCliFlags {\n preset?: string;\n category?: string;\n source?: string;\n severity?: string;\n json?: boolean;\n jsonCompact?: boolean;\n}\n\ninterface ExplainCliFlags {\n json?: boolean;\n}\n\ninterface InspectCliFlags {\n json?: boolean;\n jsonCompact?: boolean;\n}\n\ninterface ProjectInfoJsonPayload {\n framework: string;\n rootDirectory: string;\n packageJsonPath: string | null;\n vueVersion: string | null;\n nuxtVersion: string | null;\n nuxtCompatibilityVersion: 3 | 4 | null;\n nitroPreset: string | null;\n typescriptVersion: string | null;\n monorepoKind: string | null;\n hasAutoImports: boolean;\n hasComponentsAutoImport: boolean;\n hasPinia: boolean;\n hasVueRouter: boolean;\n capabilities: string[];\n}\n\nfunction isCiEnvironment(): boolean {\n const env = process.env;\n return Boolean(\n env.CI === 'true' ||\n env.CI === '1' ||\n env.GITHUB_ACTIONS === 'true' ||\n env.GITLAB_CI === 'true' ||\n env.CIRCLECI === 'true' ||\n env.TRAVIS === 'true' ||\n env.BUILDKITE === 'true' ||\n env.JENKINS_HOME,\n );\n}\n\nfunction projectInfoToJson(p: ProjectInfo): ProjectInfoJsonPayload {\n return {\n framework: p.framework,\n rootDirectory: p.rootDirectory,\n packageJsonPath: p.packageJsonPath,\n vueVersion: p.vueVersion,\n nuxtVersion: p.nuxtVersion,\n nuxtCompatibilityVersion: p.nuxtCompatibilityVersion,\n nitroPreset: p.nitroPreset,\n typescriptVersion: p.typescriptVersion,\n monorepoKind: p.monorepoKind,\n hasAutoImports: p.hasAutoImports,\n hasComponentsAutoImport: p.hasComponentsAutoImport,\n hasPinia: p.hasPinia,\n hasVueRouter: p.hasVueRouter,\n capabilities: [...p.capabilities].sort(),\n };\n}\n\nfunction renderInspect(p: ProjectInfo, rootDir: string): string {\n const lines: string[] = [];\n lines.push(`@geoql/nuxt-doctor v${readVersion()} — project capabilities`);\n lines.push('');\n lines.push('framework');\n lines.push(` ${p.framework}`);\n lines.push(` vue: ${p.vueVersion ?? '(none)'}`);\n lines.push(` typescript: ${p.typescriptVersion ?? '(none)'}`);\n lines.push('');\n lines.push('project layout');\n lines.push(` rootDirectory: ${rootDir}`);\n lines.push(` packageJsonPath: ${p.packageJsonPath ?? '(none)'}`);\n lines.push(` monorepoKind: ${p.monorepoKind ?? '(none)'}`);\n lines.push('');\n lines.push('ecosystem');\n lines.push(` hasAutoImports: ${p.hasAutoImports}`);\n lines.push(` hasComponentsAutoImport: ${p.hasComponentsAutoImport}`);\n lines.push(` hasPinia: ${p.hasPinia}`);\n lines.push(` hasVueRouter: ${p.hasVueRouter}`);\n lines.push('');\n lines.push('capability tokens (used by rule gating)');\n lines.push(` ${[...p.capabilities].sort().join('\\n ')}`);\n lines.push('');\n lines.push(\"run 'nuxt-doctor inspect --json' for machine output\");\n lines.push(\n \"run 'nuxt-doctor list-rules' to see which rules these capabilities enable\",\n );\n return `${lines.join('\\n')}\\n`;\n}\n\ninterface ExplainableDoc {\n id: string;\n severity: string;\n category: string;\n source: string;\n recommended: boolean;\n helpUri: string;\n description: string;\n hasOverride: boolean;\n}\n\nfunction renderExplain(doc: ExplainableDoc): string {\n const lines: string[] = [];\n lines.push(`Rule: ${doc.id}`);\n lines.push(`Severity: ${doc.severity}`);\n lines.push(`Category: ${doc.category}`);\n lines.push(`Source: ${doc.source}`);\n lines.push(\n `Recommended: ${doc.recommended ? 'yes' : 'no (off in `recommended` preset)'}`,\n );\n lines.push(`Help: ${doc.helpUri}`);\n lines.push('');\n lines.push(doc.description);\n return `${lines.join('\\n')}\\n`;\n}\n\nconst VALID_LIST_PRESETS = new Set(['recommended', 'all']);\nconst VALID_CATEGORIES = new Set<RuleCategory>([\n 'ai-slop',\n 'reactivity',\n 'composition',\n 'performance',\n 'template',\n 'template-perf',\n 'build-quality',\n 'deps',\n 'dead-code',\n 'sfc',\n 'vue-builtin',\n 'structure',\n 'modules-deps',\n 'nitro',\n 'seo',\n 'cloudflare',\n 'server-routes',\n 'hydration',\n 'data-fetching',\n]);\nconst VALID_SOURCES = new Set<RuleSource>([\n 'doctor',\n 'oxlint-builtin',\n 'eslint-plugin-vue',\n]);\n\nfunction buildListRulesFilter(flags: ListRulesCliFlags): ListRulesFilter {\n const out: {\n preset?: 'recommended' | 'all';\n category?: RuleCategory;\n source?: RuleSource;\n severity?: Severity;\n } = {};\n if (flags.preset !== undefined) {\n if (!VALID_LIST_PRESETS.has(flags.preset)) {\n throw new Error(\n `unknown --preset '${flags.preset}' (expected: recommended | all)`,\n );\n }\n out.preset = flags.preset as 'recommended' | 'all';\n }\n if (flags.category !== undefined) {\n if (!VALID_CATEGORIES.has(flags.category as RuleCategory)) {\n throw new Error(`unknown --category '${flags.category}'`);\n }\n out.category = flags.category as RuleCategory;\n }\n if (flags.source !== undefined) {\n if (!VALID_SOURCES.has(flags.source as RuleSource)) {\n throw new Error(`unknown --source '${flags.source}'`);\n }\n out.source = flags.source as RuleSource;\n }\n if (flags.severity !== undefined) {\n if (\n flags.severity !== 'error' &&\n flags.severity !== 'warn' &&\n flags.severity !== 'info'\n ) {\n throw new Error(\n `unknown --severity '${flags.severity}' (expected: error | warn | info)`,\n );\n }\n out.severity = flags.severity;\n }\n return out;\n}\n\nfunction renderRulesTable(rules: RegisteredRule[]): string {\n if (rules.length === 0) return 'No rules matched.\\n';\n const lines: string[] = [\n `@geoql/nuxt-doctor — ${rules.length} rule${rules.length === 1 ? '' : 's'}`,\n '',\n ];\n const idWidth = Math.max(...rules.map((r) => r.id.length));\n const sevWidth = Math.max(...rules.map((r) => r.severity.length));\n const catWidth = Math.max(...rules.map((r) => r.category.length));\n for (const r of rules) {\n const tag = r.recommended ? '[recommended]' : ' ';\n lines.push(\n ` ${r.id.padEnd(idWidth)} ${r.severity.padEnd(sevWidth)} ${r.category.padEnd(catWidth)} ${r.source} ${tag}`,\n );\n }\n return `${lines.join('\\n')}\\n`;\n}\n\ninterface CliFlags {\n format?: string;\n config?: string;\n preset?: string;\n failOn?: string;\n json?: boolean;\n jsonCompact?: boolean;\n color?: boolean;\n quiet?: boolean;\n verbose?: boolean;\n output?: string;\n rule?: string | string[];\n include?: string | string[];\n exclude?: string | string[];\n deadCode?: boolean;\n lint?: boolean;\n respectInlineDisables?: boolean;\n threshold?: string;\n score?: boolean;\n annotations?: boolean;\n ci?: boolean;\n diff?: boolean;\n staged?: boolean;\n full?: boolean;\n}\n\nfunction toArray(value: string | string[] | undefined): string[] | undefined {\n if (value === undefined) return undefined;\n return Array.isArray(value) ? value : [value];\n}\n\nfunction parseRuleOverrides(\n rules: string[] | undefined,\n): Record<string, Severity | 'off'> | undefined {\n if (!rules || rules.length === 0) return undefined;\n const out: Record<string, Severity | 'off'> = {};\n for (const entry of rules) {\n const idx = entry.lastIndexOf(':');\n if (idx === -1) {\n throw new Error(\n `Invalid --rule \"${entry}\". Expected format <ruleId>:<error|warn|info|off>.`,\n );\n }\n const ruleId = entry.slice(0, idx);\n const level = entry.slice(idx + 1);\n if (\n level !== 'error' &&\n level !== 'warn' &&\n level !== 'info' &&\n level !== 'off'\n ) {\n throw new Error(\n `Invalid severity \"${level}\" for --rule \"${entry}\". Expected error|warn|info|off.`,\n );\n }\n if (ruleId.length === 0) {\n throw new Error(`Invalid --rule \"${entry}\". Rule id must not be empty.`);\n }\n out[ruleId] = level;\n }\n return out;\n}\n\nfunction resolveFormat(flags: CliFlags): ReporterFormat {\n if (flags.jsonCompact) return 'json-compact';\n if (flags.json) return 'json';\n const kind = flags.format;\n const userPickedFormat =\n kind === 'pretty' ||\n kind === 'json' ||\n kind === 'json-compact' ||\n kind === 'sarif' ||\n kind === 'html';\n if (userPickedFormat) {\n return kind;\n }\n if (\n typeof flags.output === 'string' &&\n flags.output.toLowerCase().endsWith('.html')\n ) {\n return 'html';\n }\n return 'agent';\n}\n\nfunction isFailOnLevel(v: string): v is 'error' | 'warn' | 'none' {\n return v === 'error' || v === 'warn' || v === 'none';\n}\n\nexport async function run(argv: string[] = process.argv): Promise<number> {\n const cli = cac('nuxt-doctor');\n\n cli\n .command('[path]', 'Audit a Nuxt project')\n .option(\n '--format <kind>',\n 'Output format (agent|pretty|json|json-compact|sarif|html)',\n {\n default: 'agent',\n },\n )\n .option('--json', 'Shorthand for --format json')\n .option('--json-compact', 'Emit single-line JSON')\n .option('--config <path>', 'Path to doctor.config.ts')\n .option('--preset <name>', 'Base preset: minimal|recommended|strict|all')\n .option(\n '--fail-on <level>',\n 'Exit non-zero on this severity or worse (error|warn|none)',\n {\n default: 'error',\n },\n )\n .option('--quiet', 'Only show the summary')\n .option('--verbose', 'Emit per-pass timing and rule diagnostics to stderr')\n .option('--no-color', 'Disable colored output')\n .option(\n '--rule <id:level>',\n 'Override a rule (repeatable), e.g. --rule a/b:off',\n )\n .option('--include <glob>', 'Glob of files to include (repeatable)')\n .option('--exclude <glob>', 'Glob of files to exclude (repeatable)')\n .option('--no-dead-code', 'Skip the dead-code (knip) analysis pass')\n .option('--no-lint', 'Skip the lint passes (template/SFC/oxlint)')\n .option(\n '--no-respect-inline-disables',\n 'Surface findings even inside doctor-disable comments',\n )\n .option('--threshold <n>', 'Minimum passing score (0-100)')\n .option('--score', 'Output only the numeric score (for piping)')\n .option('--annotations', 'Emit GitHub Actions ::error::/::warning:: lines')\n .option('--ci', 'Auto-enable CI behavior (--annotations on GitHub Actions)')\n .option('--no-ci', 'Disable CI auto-detection even when CI env is set')\n .option('--diff', 'Only report findings in files changed vs HEAD')\n .option('--staged', 'Only report findings in staged files')\n .option('--full', 'Force a complete scan (overrides --diff/--staged)')\n .option('--output <file>', 'Write the report to a file instead of stdout')\n .action(async (path: string | undefined, flags: CliFlags) => {\n const reporter = resolveFormat(flags);\n if (flags.failOn !== undefined && !isFailOnLevel(flags.failOn)) {\n process.stderr.write(\n `nuxt-doctor: --fail-on must be 'error', 'warn', or 'none', got '${flags.failOn}'\\n`,\n );\n process.exitCode = 2;\n return;\n }\n const rootDir = resolve(path ?? '.');\n\n try {\n if (flags.score && (flags.json || flags.jsonCompact)) {\n throw new Error(\n '--score and --json are mutually exclusive (--score outputs a plaintext integer).',\n );\n }\n const ruleOverrides = parseRuleOverrides(toArray(flags.rule));\n const threshold =\n flags.threshold === undefined ? undefined : Number(flags.threshold);\n if (\n threshold !== undefined &&\n (!Number.isInteger(threshold) || threshold < 0 || threshold > 100)\n ) {\n throw new Error(\n `--threshold must be an integer 0-100, got \"${flags.threshold}\".`,\n );\n }\n if (flags.diff && flags.staged) {\n throw new Error('--diff and --staged are mutually exclusive.');\n }\n if (flags.verbose && flags.quiet) {\n throw new Error('--verbose and --quiet are mutually exclusive.');\n }\n let scopeFiles: string[] | undefined;\n if (!flags.full && (flags.diff || flags.staged)) {\n scopeFiles = await listChangedFiles({\n rootDir,\n mode: flags.staged ? 'staged' : 'diff',\n });\n }\n const resolved = await loadDoctorConfig(rootDir, {\n ...(flags.config ? { explicitPath: flags.config } : {}),\n ...(flags.preset ? { presetOverride: flags.preset } : {}),\n });\n const merged = mergeCliOverrides(resolved, {\n failOn: flags.failOn as 'error' | 'warn' | 'none' | undefined,\n include: toArray(flags.include),\n exclude: toArray(flags.exclude),\n rules: ruleOverrides,\n threshold,\n });\n const report = await audit({\n rootDir: merged.rootDir,\n include: merged.include,\n exclude: merged.exclude,\n rules: merged.rules,\n failOn: merged.failOn,\n threshold: merged.threshold,\n deadCode: flags.deadCode,\n lint: flags.lint,\n respectInlineDisables: flags.respectInlineDisables,\n scopeFiles,\n });\n const allowedRuleIds = new Set(Object.keys(merged.rules));\n report.diagnostics = report.diagnostics.filter((d) =>\n allowedRuleIds.has(d.ruleId),\n );\n if (flags.verbose) {\n const verboseOutput = renderVerboseTrace(report, {\n configSource: resolved.source,\n });\n process.stderr.write(`${verboseOutput}\\n`);\n }\n if (flags.score) {\n process.stdout.write(`${report.score}\\n`);\n process.exitCode = report.exitCode;\n return;\n }\n const input: ReporterInput = {\n toolName: '@geoql/nuxt-doctor',\n toolVersion: readVersion(),\n rootDirectory: report.rootDir,\n analyzedFileCount: report.filesScanned,\n elapsedMs: report.elapsedMs,\n diagnostics: report.diagnostics,\n score: report.scoreResult,\n projectInfo: report.projectInfo,\n };\n const out = format(input, reporter, {\n color: flags.color,\n quiet: flags.quiet,\n });\n if (flags.output) {\n writeFileSync(resolve(flags.output), out);\n } else {\n process.stdout.write(out);\n }\n const ciExplicitOptOut = flags.ci === false;\n const ciExplicitOptIn = flags.ci === true;\n const ciAutoDetected = !ciExplicitOptOut && isCiEnvironment();\n const wantsAnnotations =\n flags.annotations === true || ciExplicitOptIn || ciAutoDetected;\n const reporterCarriesAnnotations =\n reporter === 'agent' || reporter === 'pretty';\n if (\n wantsAnnotations &&\n reporterCarriesAnnotations &&\n !flags.quiet &&\n report.diagnostics.length > 0\n ) {\n process.stdout.write(`${encodeAnnotations(report.diagnostics)}\\n`);\n }\n process.exitCode = report.exitCode;\n } catch (err) {\n const msg = err instanceof Error ? err.message : String(err);\n process.stderr.write(`nuxt-doctor: ${msg}\\n`);\n process.exitCode = 2;\n }\n });\n\n cli\n .command(\n 'list-rules',\n 'List every registered rule with id, severity, category, source, and preset membership',\n )\n .option('--preset <name>', 'Filter to: recommended | all')\n .option('--category <name>', 'Filter by category')\n .option(\n '--source <name>',\n 'Filter by source: doctor | oxlint-builtin | eslint-plugin-vue',\n )\n .option('--severity <level>', 'Filter by: error | warn | info')\n .option('--json', 'Emit JSON instead of formatted text')\n .option('--json-compact', 'With --json, single-line output')\n .action(async (flags: ListRulesCliFlags) => {\n try {\n const filter = buildListRulesFilter(flags);\n const rules = listRules(filter);\n if (flags.json || flags.jsonCompact) {\n const payload = { count: rules.length, rules };\n process.stdout.write(\n flags.jsonCompact\n ? JSON.stringify(payload)\n : `${JSON.stringify(payload, null, 2)}\\n`,\n );\n } else {\n process.stdout.write(renderRulesTable(rules));\n }\n process.exitCode = 0;\n } catch (err) {\n const msg = (err as Error).message;\n process.stderr.write(`nuxt-doctor list-rules: ${msg}\\n`);\n process.exitCode = 2;\n }\n });\n\n cli\n .command(\n 'explain <ruleId>',\n \"Print the rule's severity, category, recommendation, and helpUri\",\n )\n .option('--json', 'Emit structured JSON instead of formatted text')\n .action(async (ruleId: string, flags: ExplainCliFlags) => {\n const doc = loadRuleDoc(ruleId);\n if (!doc) {\n process.stderr.write(\n `nuxt-doctor explain: unknown rule '${ruleId}'. Try \\`nuxt-doctor list-rules\\` to see registered rules.\\n`,\n );\n process.exitCode = 2;\n return;\n }\n if (flags.json) {\n process.stdout.write(`${JSON.stringify(doc, null, 2)}\\n`);\n } else {\n process.stdout.write(renderExplain(doc));\n }\n process.exitCode = 0;\n });\n\n cli\n .command(\n 'inspect [dir]',\n 'Print the detected project capabilities doctor uses to gate rules',\n )\n .option('--json', 'Emit structured JSON instead of formatted text')\n .option('--json-compact', 'With --json, emit a single-line payload')\n .action(async (dir: string | undefined, flags: InspectCliFlags) => {\n const rootDir = resolve(dir ?? '.');\n const project = await detectProject(rootDir);\n if (flags.json || flags.jsonCompact) {\n const payload = projectInfoToJson(project);\n const out = flags.jsonCompact\n ? JSON.stringify(payload)\n : JSON.stringify(payload, null, 2);\n process.stdout.write(`${out}\\n`);\n } else {\n process.stdout.write(renderInspect(project, rootDir));\n }\n process.exitCode = 0;\n });\n\n cli.help();\n cli.version(readVersion());\n cli.parse(argv, { run: false });\n await cli.runMatchedCommand();\n return process.exitCode ?? 0;\n}\n"],"mappings":";;;;;;;AA0BA,SAAS,cAAsB;CAC7B,IAAI;EACF,MAAM,OAAO,QAAQ,cAAc,OAAO,KAAK,IAAI,CAAC;EAIpD,OAHY,KAAK,MACf,aAAa,QAAQ,MAAM,kBAAkB,EAAE,QAAQ,CAE/C,CAAC,WAAW;SAChB;EACN,OAAO;;;AAuCX,SAAS,kBAA2B;CAClC,MAAM,MAAM,QAAQ;CACpB,OAAO,QACL,IAAI,OAAO,UACX,IAAI,OAAO,OACX,IAAI,mBAAmB,UACvB,IAAI,cAAc,UAClB,IAAI,aAAa,UACjB,IAAI,WAAW,UACf,IAAI,cAAc,UAClB,IAAI,aACL;;AAGH,SAAS,kBAAkB,GAAwC;CACjE,OAAO;EACL,WAAW,EAAE;EACb,eAAe,EAAE;EACjB,iBAAiB,EAAE;EACnB,YAAY,EAAE;EACd,aAAa,EAAE;EACf,0BAA0B,EAAE;EAC5B,aAAa,EAAE;EACf,mBAAmB,EAAE;EACrB,cAAc,EAAE;EAChB,gBAAgB,EAAE;EAClB,yBAAyB,EAAE;EAC3B,UAAU,EAAE;EACZ,cAAc,EAAE;EA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GAC1C,MAAM,MAAM,MAAM,cACd,KAAK,UAAU,QAAQ,GACvB,KAAK,UAAU,SAAS,MAAM,EAAE;GACpC,QAAQ,OAAO,MAAM,GAAG,IAAI,IAAI;SAEhC,QAAQ,OAAO,MAAM,cAAc,SAAS,QAAQ,CAAC;EAEvD,QAAQ,WAAW;GACnB;CAEJ,IAAI,MAAM;CACV,IAAI,QAAQ,aAAa,CAAC;CAC1B,IAAI,MAAM,MAAM,EAAE,KAAK,OAAO,CAAC;CAC/B,MAAM,IAAI,mBAAmB;CAC7B,OAAO,QAAQ,YAAY"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../src/cli.ts"],"sourcesContent":["import { readFileSync, writeFileSync } from 'node:fs';\nimport { dirname, resolve } from 'node:path';\nimport process from 'node:process';\nimport { fileURLToPath } from 'node:url';\nimport {\n audit,\n detectProject,\n detectSummary,\n encodeAnnotations,\n findMonorepoRoot,\n format,\n listChangedFiles,\n listRules,\n listWorkspacePackages,\n loadDoctorConfig,\n loadRuleDoc,\n mergeCliOverrides,\n normalizeInitAnswers,\n planInit,\n renderVerboseTrace,\n scoreDiagnostics,\n type AuditReport,\n type ConfigSource,\n type InitConfigFormat,\n type ListRulesFilter,\n type ProjectInfo,\n type RegisteredRule,\n type ReporterFormat,\n type ReporterInput,\n type ResolvedDoctorConfig,\n type RuleCategory,\n type RuleSource,\n type Severity,\n type WorkspacePackage,\n} from '@geoql/doctor-core';\nimport { cac } from 'cac';\nimport prompts from 'prompts';\n\nfunction readVersion(): string {\n try {\n const here = dirname(fileURLToPath(import.meta.url));\n const pkg = JSON.parse(\n readFileSync(resolve(here, '../package.json'), 'utf-8'),\n ) as { version?: string };\n return pkg.version ?? '0.0.0';\n } catch {\n return '0.0.0';\n }\n}\n\ninterface ListRulesCliFlags {\n preset?: string;\n category?: string;\n source?: string;\n severity?: string;\n json?: boolean;\n jsonCompact?: boolean;\n}\n\ninterface ExplainCliFlags {\n json?: boolean;\n}\n\ninterface InspectCliFlags {\n json?: boolean;\n jsonCompact?: boolean;\n}\n\ninterface InitCliFlags {\n yes?: boolean;\n configFormat?: string;\n force?: boolean;\n dryRun?: boolean;\n}\n\ninterface ProjectInfoJsonPayload {\n framework: string;\n rootDirectory: string;\n packageJsonPath: string | null;\n vueVersion: string | null;\n nuxtVersion: string | null;\n nuxtCompatibilityVersion: 3 | 4 | null;\n nitroPreset: string | null;\n typescriptVersion: string | null;\n monorepoKind: string | null;\n hasAutoImports: boolean;\n hasComponentsAutoImport: boolean;\n hasPinia: boolean;\n hasVueRouter: boolean;\n capabilities: string[];\n}\n\nfunction isCiEnvironment(): boolean {\n const env = process.env;\n return Boolean(\n env.CI === 'true' ||\n env.CI === '1' ||\n env.GITHUB_ACTIONS === 'true' ||\n env.GITLAB_CI === 'true' ||\n env.CIRCLECI === 'true' ||\n env.TRAVIS === 'true' ||\n env.BUILDKITE === 'true' ||\n env.JENKINS_HOME,\n );\n}\n\nfunction projectInfoToJson(p: ProjectInfo): ProjectInfoJsonPayload {\n return {\n framework: p.framework,\n rootDirectory: p.rootDirectory,\n packageJsonPath: p.packageJsonPath,\n vueVersion: p.vueVersion,\n nuxtVersion: p.nuxtVersion,\n nuxtCompatibilityVersion: p.nuxtCompatibilityVersion,\n nitroPreset: p.nitroPreset,\n typescriptVersion: p.typescriptVersion,\n monorepoKind: p.monorepoKind,\n hasAutoImports: p.hasAutoImports,\n hasComponentsAutoImport: p.hasComponentsAutoImport,\n hasPinia: p.hasPinia,\n hasVueRouter: p.hasVueRouter,\n capabilities: [...p.capabilities].sort(),\n };\n}\n\nfunction renderInspect(p: ProjectInfo, rootDir: string): string {\n const lines: string[] = [];\n lines.push(`@geoql/nuxt-doctor v${readVersion()} — project capabilities`);\n lines.push('');\n lines.push('framework');\n lines.push(` ${p.framework}`);\n lines.push(` nuxt: ${p.nuxtVersion ?? '(none)'}`);\n lines.push(` typescript: ${p.typescriptVersion ?? '(none)'}`);\n lines.push('');\n lines.push('project layout');\n lines.push(` rootDirectory: ${rootDir}`);\n lines.push(` packageJsonPath: ${p.packageJsonPath ?? '(none)'}`);\n lines.push(` monorepoKind: ${p.monorepoKind ?? '(none)'}`);\n lines.push('');\n lines.push('ecosystem');\n lines.push(` hasAutoImports: ${p.hasAutoImports}`);\n lines.push(` hasComponentsAutoImport: ${p.hasComponentsAutoImport}`);\n lines.push(` hasPinia: ${p.hasPinia}`);\n lines.push(` hasVueRouter: ${p.hasVueRouter}`);\n lines.push('');\n lines.push('capability tokens (used by rule gating)');\n lines.push(` ${[...p.capabilities].sort().join('\\n ')}`);\n lines.push('');\n lines.push(\"run 'nuxt-doctor inspect --json' for machine output\");\n lines.push(\n \"run 'nuxt-doctor list-rules' to see which rules these capabilities enable\",\n );\n return `${lines.join('\\n')}\\n`;\n}\n\ninterface ExplainableDoc {\n id: string;\n severity: string;\n category: string;\n source: string;\n recommended: boolean;\n helpUri: string;\n description: string;\n hasOverride: boolean;\n}\n\nfunction renderExplain(doc: ExplainableDoc): string {\n const lines: string[] = [];\n lines.push(`Rule: ${doc.id}`);\n lines.push(`Severity: ${doc.severity}`);\n lines.push(`Category: ${doc.category}`);\n lines.push(`Source: ${doc.source}`);\n lines.push(\n `Recommended: ${doc.recommended ? 'yes' : 'no (off in `recommended` preset)'}`,\n );\n lines.push(`Help: ${doc.helpUri}`);\n lines.push('');\n lines.push(doc.description);\n return `${lines.join('\\n')}\\n`;\n}\n\nconst VALID_LIST_PRESETS = new Set(['recommended', 'all']);\nconst VALID_CATEGORIES = new Set<RuleCategory>([\n 'ai-slop',\n 'reactivity',\n 'composition',\n 'performance',\n 'template',\n 'template-perf',\n 'build-quality',\n 'deps',\n 'dead-code',\n 'sfc',\n 'vue-builtin',\n 'structure',\n 'modules-deps',\n 'nitro',\n 'seo',\n 'cloudflare',\n 'server-routes',\n 'hydration',\n 'data-fetching',\n]);\nconst VALID_SOURCES = new Set<RuleSource>([\n 'doctor',\n 'oxlint-builtin',\n 'eslint-plugin-vue',\n]);\nconst VALID_CONFIG_FORMATS = new Set(['ts', 'json', 'package-json']);\n\nfunction buildListRulesFilter(flags: ListRulesCliFlags): ListRulesFilter {\n const out: {\n preset?: 'recommended' | 'all';\n category?: RuleCategory;\n source?: RuleSource;\n severity?: Severity;\n } = {};\n if (flags.preset !== undefined) {\n if (!VALID_LIST_PRESETS.has(flags.preset)) {\n throw new Error(\n `unknown --preset '${flags.preset}' (expected: recommended | all)`,\n );\n }\n out.preset = flags.preset as 'recommended' | 'all';\n }\n if (flags.category !== undefined) {\n if (!VALID_CATEGORIES.has(flags.category as RuleCategory)) {\n throw new Error(`unknown --category '${flags.category}'`);\n }\n out.category = flags.category as RuleCategory;\n }\n if (flags.source !== undefined) {\n if (!VALID_SOURCES.has(flags.source as RuleSource)) {\n throw new Error(`unknown --source '${flags.source}'`);\n }\n out.source = flags.source as RuleSource;\n }\n if (flags.severity !== undefined) {\n if (\n flags.severity !== 'error' &&\n flags.severity !== 'warn' &&\n flags.severity !== 'info'\n ) {\n throw new Error(\n `unknown --severity '${flags.severity}' (expected: error | warn | info)`,\n );\n }\n out.severity = flags.severity;\n }\n return out;\n}\n\nfunction renderRulesTable(rules: RegisteredRule[]): string {\n if (rules.length === 0) return 'No rules matched.\\n';\n const lines: string[] = [\n `@geoql/nuxt-doctor — ${rules.length} rule${rules.length === 1 ? '' : 's'}`,\n '',\n ];\n const idWidth = Math.max(...rules.map((r) => r.id.length));\n const sevWidth = Math.max(...rules.map((r) => r.severity.length));\n const catWidth = Math.max(...rules.map((r) => r.category.length));\n for (const r of rules) {\n const tag = r.recommended ? '[recommended]' : ' ';\n lines.push(\n ` ${r.id.padEnd(idWidth)} ${r.severity.padEnd(sevWidth)} ${r.category.padEnd(catWidth)} ${r.source} ${tag}`,\n );\n }\n return `${lines.join('\\n')}\\n`;\n}\n\ninterface CliFlags {\n format?: string;\n config?: string;\n preset?: string;\n failOn?: string;\n json?: boolean;\n jsonCompact?: boolean;\n color?: boolean;\n quiet?: boolean;\n verbose?: boolean;\n output?: string;\n rule?: string | string[];\n include?: string | string[];\n exclude?: string | string[];\n deadCode?: boolean;\n lint?: boolean;\n respectInlineDisables?: boolean;\n threshold?: string;\n score?: boolean;\n annotations?: boolean;\n ci?: boolean;\n diff?: boolean;\n staged?: boolean;\n full?: boolean;\n project?: string;\n prComment?: string | true;\n fix?: boolean;\n fixExclude?: string | string[];\n}\n\ninterface PreparedOptions {\n ruleOverrides: Record<string, Severity | 'off'> | undefined;\n threshold: number | undefined;\n}\n\nfunction toArray(value: string | string[] | undefined): string[] | undefined {\n if (value === undefined) return undefined;\n return Array.isArray(value) ? value : [value];\n}\n\nfunction parseRuleOverrides(\n rules: string[] | undefined,\n): Record<string, Severity | 'off'> | undefined {\n if (!rules || rules.length === 0) return undefined;\n const out: Record<string, Severity | 'off'> = {};\n for (const entry of rules) {\n const idx = entry.lastIndexOf(':');\n if (idx === -1) {\n throw new Error(\n `Invalid --rule \"${entry}\". Expected format <ruleId>:<error|warn|info|off>.`,\n );\n }\n const ruleId = entry.slice(0, idx);\n const level = entry.slice(idx + 1);\n if (\n level !== 'error' &&\n level !== 'warn' &&\n level !== 'info' &&\n level !== 'off'\n ) {\n throw new Error(\n `Invalid severity \"${level}\" for --rule \"${entry}\". Expected error|warn|info|off.`,\n );\n }\n if (ruleId.length === 0) {\n throw new Error(`Invalid --rule \"${entry}\". Rule id must not be empty.`);\n }\n out[ruleId] = level;\n }\n return out;\n}\n\nfunction resolveFormat(flags: CliFlags): ReporterFormat {\n if (flags.prComment !== undefined) return 'pr-comment';\n if (flags.jsonCompact) return 'json-compact';\n if (flags.json) return 'json';\n const kind = flags.format;\n const userPickedFormat =\n kind === 'pretty' ||\n kind === 'json' ||\n kind === 'json-compact' ||\n kind === 'sarif' ||\n kind === 'html' ||\n kind === 'pr-comment';\n if (userPickedFormat) {\n return kind as ReporterFormat;\n }\n if (\n typeof flags.output === 'string' &&\n flags.output.toLowerCase().endsWith('.html')\n ) {\n return 'html';\n }\n return 'agent';\n}\n\nfunction isFailOnLevel(v: string): v is 'error' | 'warn' | 'none' {\n return v === 'error' || v === 'warn' || v === 'none';\n}\n\nasync function runSingleAudit(\n rootDir: string,\n flags: CliFlags,\n prepared: PreparedOptions,\n): Promise<{ report: AuditReport; source: ConfigSource }> {\n let scopeFiles: string[] | undefined;\n if (!flags.full && (flags.diff || flags.staged)) {\n scopeFiles = await listChangedFiles({\n rootDir,\n mode: flags.staged ? 'staged' : 'diff',\n });\n }\n const resolved = await loadDoctorConfig(rootDir, {\n ...(flags.config ? { explicitPath: flags.config } : {}),\n ...(flags.preset ? { presetOverride: flags.preset } : {}),\n });\n const fixExclude = toArray(flags.fixExclude);\n const merged: ResolvedDoctorConfig = mergeCliOverrides(resolved, {\n failOn: flags.failOn as 'error' | 'warn' | 'none' | undefined,\n include: toArray(flags.include),\n exclude: toArray(flags.exclude),\n rules: prepared.ruleOverrides,\n threshold: prepared.threshold,\n ...(fixExclude ? { fixExcludes: fixExclude } : {}),\n });\n const report = await audit({\n rootDir: merged.rootDir,\n include: merged.include,\n exclude: merged.exclude,\n rules: merged.rules,\n failOn: merged.failOn,\n threshold: merged.threshold,\n deadCode: flags.deadCode,\n lint: flags.lint,\n respectInlineDisables: flags.respectInlineDisables,\n scopeFiles,\n fix: flags.fix,\n ...(merged.fixExcludes ? { fixExcludes: merged.fixExcludes } : {}),\n });\n const allowedRuleIds = new Set(Object.keys(merged.rules));\n report.diagnostics = report.diagnostics.filter((d) =>\n allowedRuleIds.has(d.ruleId),\n );\n return { report, source: resolved.source };\n}\n\nfunction aggregateReports(\n reports: AuditReport[],\n rootDirectory: string,\n): AuditReport {\n const first = reports[0];\n const diagnostics = reports.flatMap((r) => r.diagnostics);\n let filesScanned = 0;\n let elapsedMs = 0;\n let exitCode: 0 | 1 | 2 = 0;\n for (const r of reports) {\n filesScanned += r.filesScanned;\n elapsedMs += r.elapsedMs;\n if (r.exitCode > exitCode) exitCode = r.exitCode;\n }\n const ruleCounts: Record<string, number> = {};\n for (const d of diagnostics) {\n ruleCounts[d.ruleId] = (ruleCounts[d.ruleId] ?? 0) + 1;\n }\n const scoreResult = scoreDiagnostics(diagnostics, {\n threshold: first.scoreResult.threshold,\n });\n return {\n rootDir: rootDirectory,\n filesScanned,\n diagnostics,\n score: scoreResult.score,\n errorCount: scoreResult.errorCount,\n warnCount: scoreResult.warnCount,\n infoCount: scoreResult.infoCount,\n exitCode,\n scoreResult,\n projectInfo: { ...first.projectInfo, rootDirectory },\n elapsedMs,\n timings: first.timings,\n ruleCounts,\n };\n}\n\nfunction emitReport(\n report: AuditReport,\n reporter: ReporterFormat,\n flags: CliFlags,\n): void {\n const input: ReporterInput = {\n toolName: '@geoql/nuxt-doctor',\n toolVersion: readVersion(),\n rootDirectory: report.rootDir,\n analyzedFileCount: report.filesScanned,\n elapsedMs: report.elapsedMs,\n diagnostics: report.diagnostics,\n score: report.scoreResult,\n projectInfo: report.projectInfo,\n };\n const out = format(input, reporter, {\n color: flags.color,\n quiet: flags.quiet,\n });\n if (flags.output) {\n writeFileSync(resolve(flags.output), out);\n } else {\n process.stdout.write(out);\n }\n const ciExplicitOptOut = flags.ci === false;\n const ciExplicitOptIn = flags.ci === true;\n const ciAutoDetected = !ciExplicitOptOut && isCiEnvironment();\n const wantsAnnotations =\n flags.annotations === true || ciExplicitOptIn || ciAutoDetected;\n const reporterCarriesAnnotations =\n reporter === 'agent' || reporter === 'pretty';\n if (\n wantsAnnotations &&\n reporterCarriesAnnotations &&\n !flags.quiet &&\n report.diagnostics.length > 0\n ) {\n process.stdout.write(`${encodeAnnotations(report.diagnostics)}\\n`);\n }\n}\n\nasync function runProjectAudits(\n rootDir: string,\n flags: CliFlags,\n prepared: PreparedOptions,\n packages: WorkspacePackage[],\n): Promise<{ report: AuditReport; source: ConfigSource } | null> {\n const requested = flags\n .project!.split(',')\n .map((name) => name.trim())\n .filter((name) => name.length > 0);\n const byName = new Map(packages.map((p) => [p.name, p]));\n const reports: AuditReport[] = [];\n let source: ConfigSource = 'built-in';\n for (const name of requested) {\n const match = byName.get(name);\n if (!match) {\n process.stderr.write(\n `nuxt-doctor: --project: unknown project \"${name}\" (skipped)\\n`,\n );\n continue;\n }\n const single = await runSingleAudit(match.dir, flags, prepared);\n reports.push(single.report);\n source = single.source;\n }\n if (reports.length === 0) {\n process.stderr.write(\n 'nuxt-doctor: --project: no matching workspace projects\\n',\n );\n return null;\n }\n const { root } = await findMonorepoRoot(rootDir);\n return { report: aggregateReports(reports, root), source };\n}\n\nasync function runInit(dir: string, flags: InitCliFlags): Promise<void> {\n const targetDir = resolve(dir);\n const configFormat = (flags.configFormat ?? 'ts') as InitConfigFormat;\n if (!VALID_CONFIG_FORMATS.has(configFormat)) {\n process.stderr.write(\n `nuxt-doctor init: --config-format must be ts | json | package-json, got '${flags.configFormat}'\\n`,\n );\n process.exitCode = 2;\n return;\n }\n\n const resolvedAnswers = flags.yes\n ? {\n configFormat,\n preset: 'recommended' as const,\n threshold: undefined,\n exclude: undefined,\n }\n : await runInteractiveInit(configFormat);\n\n if (process.exitCode === 2) return;\n\n const plan = await planInit({\n dir: targetDir,\n configFormat: resolvedAnswers.configFormat,\n preset: resolvedAnswers.preset,\n threshold: resolvedAnswers.threshold,\n exclude: resolvedAnswers.exclude,\n binName: 'nuxt-doctor',\n });\n\n const summary = await detectSummary(targetDir);\n process.stdout.write(`${summary}\\n`);\n\n if (plan.conflict && !flags.force) {\n process.stderr.write(\n `nuxt-doctor init: ${plan.conflictPath} already exists. Run with --force to overwrite.\\n`,\n );\n process.exitCode = 2;\n return;\n }\n\n if (flags.dryRun) {\n for (const write of plan.writes) {\n process.stdout.write(`[dry-run] would write ${write.path}\\n`);\n process.stdout.write(`${write.content}\\n`);\n }\n process.exitCode = 0;\n return;\n }\n\n for (const write of plan.writes) {\n writeFileSync(write.path, write.content, 'utf8');\n }\n process.exitCode = 0;\n}\n\nasync function runInteractiveInit(defaultFormat: InitConfigFormat): Promise<{\n configFormat: InitConfigFormat;\n preset: 'recommended' | 'strict' | 'minimal';\n threshold: number | undefined;\n exclude: string | undefined;\n}> {\n const answers = await prompts(\n [\n {\n type: 'select',\n name: 'target',\n message: 'Config target?',\n choices: [\n { title: 'doctor.config.ts (recommended)', value: 'ts' },\n { title: 'doctor.config.json', value: 'json' },\n { title: 'package.json#doctor', value: 'package-json' },\n ],\n initial: defaultFormat === 'package-json' ? 2 : 0,\n },\n {\n type: 'select',\n name: 'preset',\n message: 'Base preset?',\n choices: [\n { title: 'recommended (errors + warnings)', value: 'recommended' },\n { title: 'strict (recommended + info)', value: 'strict' },\n { title: 'minimal (errors only)', value: 'minimal' },\n ],\n initial: 0,\n },\n {\n type: 'number',\n name: 'threshold',\n message: 'Minimum passing score (0-100, blank to skip)',\n min: 0,\n max: 100,\n initial: '',\n },\n {\n type: 'text',\n name: 'exclude',\n message: 'Exclude glob patterns (comma-separated, blank to skip)',\n initial: '',\n },\n ],\n {\n onCancel: () => {\n process.stderr.write('nuxt-doctor init: cancelled\\n');\n process.exitCode = 2;\n },\n },\n );\n\n if (process.exitCode === 2)\n return {\n configFormat: 'ts' as InitConfigFormat,\n preset: 'recommended' as const,\n threshold: undefined,\n exclude: undefined,\n };\n\n return normalizeInitAnswers({\n target: answers.target as InitConfigFormat | undefined,\n preset: answers.preset as 'recommended' | 'strict' | 'minimal' | undefined,\n threshold: answers.threshold || undefined,\n exclude: answers.exclude as string | undefined,\n });\n}\n\nexport async function run(argv: string[] = process.argv): Promise<number> {\n const cli = cac('nuxt-doctor');\n\n cli\n .command('[path]', 'Audit a Nuxt project')\n .option(\n '--format <kind>',\n 'Output format (agent|pretty|json|json-compact|sarif|html|pr-comment)',\n {\n default: 'agent',\n },\n )\n .option('--json', 'Shorthand for --format json')\n .option('--json-compact', 'Emit single-line JSON')\n .option('--config <path>', 'Path to doctor.config.ts')\n .option('--preset <name>', 'Base preset: minimal|recommended|strict|all')\n .option(\n '--fail-on <level>',\n 'Exit non-zero on this severity or worse (error|warn|none)',\n {\n default: 'error',\n },\n )\n .option('--quiet', 'Only show the summary')\n .option('--verbose', 'Emit per-pass timing and rule diagnostics to stderr')\n .option('--no-color', 'Disable colored output')\n .option(\n '--rule <id:level>',\n 'Override a rule (repeatable), e.g. --rule a/b:off',\n )\n .option('--include <glob>', 'Glob of files to include (repeatable)')\n .option('--exclude <glob>', 'Glob of files to exclude (repeatable)')\n .option('--no-dead-code', 'Skip the dead-code (knip) analysis pass')\n .option('--no-lint', 'Skip the lint passes (template/SFC/oxlint)')\n .option(\n '--no-respect-inline-disables',\n 'Surface findings even inside doctor-disable comments',\n )\n .option('--threshold <n>', 'Minimum passing score (0-100)')\n .option('--score', 'Output only the numeric score (for piping)')\n .option('--annotations', 'Emit GitHub Actions ::error::/::warning:: lines')\n .option('--ci', 'Auto-enable CI behavior (--annotations on GitHub Actions)')\n .option('--no-ci', 'Disable CI auto-detection even when CI env is set')\n .option('--diff', 'Only report findings in files changed vs HEAD')\n .option('--staged', 'Only report findings in staged files')\n .option('--full', 'Force a complete scan (overrides --diff/--staged)')\n .option(\n '--project <name>',\n 'Comma-separated workspace project names to audit (monorepo)',\n )\n .option('--output <file>', 'Write the report to a file instead of stdout')\n .option('--pr-comment', 'Emit a focused Markdown PR-comment body')\n .option(\n '--fix',\n 'Auto-fix oxlint-pass findings in place (built-in vue/* rules only; template/SFC/dead-code/project findings are not fixable). Skipped in --diff/--staged mode.',\n )\n .option(\n '--fix-exclude <ruleId>',\n 'Mark a rule as not-auto-fixable (repeatable). Note: oxlint applies built-in fixes globally, so this is enforced only for doctor plugin fixes; built-in vue/* fixes still apply.',\n )\n .action(async (path: string | undefined, flags: CliFlags) => {\n const reporter = resolveFormat(flags);\n if (flags.failOn !== undefined && !isFailOnLevel(flags.failOn)) {\n process.stderr.write(\n `nuxt-doctor: --fail-on must be 'error', 'warn', or 'none', got '${flags.failOn}'\\n`,\n );\n process.exitCode = 2;\n return;\n }\n const rootDir = resolve(path ?? '.');\n\n try {\n if (flags.score && (flags.json || flags.jsonCompact)) {\n throw new Error(\n '--score and --json are mutually exclusive (--score outputs a plaintext integer).',\n );\n }\n const ruleOverrides = parseRuleOverrides(toArray(flags.rule));\n const threshold =\n flags.threshold === undefined ? undefined : Number(flags.threshold);\n if (\n threshold !== undefined &&\n (!Number.isInteger(threshold) || threshold < 0 || threshold > 100)\n ) {\n throw new Error(\n `--threshold must be an integer 0-100, got \"${flags.threshold}\".`,\n );\n }\n if (flags.diff && flags.staged) {\n throw new Error('--diff and --staged are mutually exclusive.');\n }\n if (flags.verbose && flags.quiet) {\n throw new Error('--verbose using --quiet are mutually exclusive.');\n }\n const fixActive = flags.fix === true;\n const fixSkippedForScope =\n fixActive && !flags.full && (flags.diff || flags.staged);\n if (fixSkippedForScope) {\n process.stderr.write(\n 'nuxt-doctor: --fix skipped in --diff/--staged mode (auto-fix only runs on a full scan to avoid rewriting files outside the diff).\\n',\n );\n }\n if (fixActive && flags.fixExclude !== undefined) {\n process.stderr.write(\n 'nuxt-doctor: --fix-exclude is not enforced for built-in vue/* rules (oxlint applies their fixes globally); it currently scopes only future doctor plugin fixes.\\n',\n );\n }\n const prepared: PreparedOptions = { ruleOverrides, threshold };\n\n const workspacePackages = flags.project\n ? await listWorkspacePackages(rootDir)\n : [];\n if (flags.project && workspacePackages.length === 0) {\n process.stderr.write(\n 'nuxt-doctor: --project ignored: not a pnpm workspace\\n',\n );\n }\n\n let report: AuditReport;\n let configSource: ConfigSource;\n if (flags.project && workspacePackages.length > 0) {\n const aggregated = await runProjectAudits(\n rootDir,\n flags,\n prepared,\n workspacePackages,\n );\n if (!aggregated) {\n process.exitCode = 2;\n return;\n }\n report = aggregated.report;\n configSource = aggregated.source;\n } else {\n const single = await runSingleAudit(rootDir, flags, prepared);\n report = single.report;\n configSource = single.source;\n }\n\n if (flags.verbose) {\n const verboseOutput = renderVerboseTrace(report, {\n configSource,\n });\n process.stderr.write(`${verboseOutput}\\n`);\n }\n if (fixActive && !fixSkippedForScope) {\n process.stderr.write(\n `nuxt-doctor: applied oxlint --fix; ${report.diagnostics.length} finding${report.diagnostics.length === 1 ? '' : 's'} remain (re-run to see them).\\n`,\n );\n }\n if (flags.score) {\n process.stdout.write(`${report.score}\\n`);\n process.exitCode = report.exitCode;\n return;\n }\n emitReport(report, reporter, flags);\n process.exitCode = report.exitCode;\n } catch (err) {\n const msg = err instanceof Error ? err.message : String(err);\n process.stderr.write(`nuxt-doctor: ${msg}\\n`);\n process.exitCode = 2;\n }\n });\n\n cli\n .command(\n 'list-rules',\n 'List every registered rule with id, severity, category, source, and preset membership',\n )\n .option('--preset <name>', 'Filter to: recommended | all')\n .option('--category <name>', 'Filter by category')\n .option(\n '--source <name>',\n 'Filter by source: doctor | oxlint-builtin | eslint-plugin-vue',\n )\n .option('--severity <level>', 'Filter by: error | warn | info')\n .option('--json', 'Emit JSON instead of formatted text')\n .option('--json-compact', 'With --json, single-line output')\n .action(async (flags: ListRulesCliFlags) => {\n try {\n const filter = buildListRulesFilter(flags);\n const rules = listRules(filter);\n if (flags.json || flags.jsonCompact) {\n const payload = { count: rules.length, rules };\n process.stdout.write(\n flags.jsonCompact\n ? JSON.stringify(payload)\n : `${JSON.stringify(payload, null, 2)}\\n`,\n );\n } else {\n process.stdout.write(renderRulesTable(rules));\n }\n process.exitCode = 0;\n } catch (err) {\n const msg = (err as Error).message;\n process.stderr.write(`nuxt-doctor list-rules: ${msg}\\n`);\n process.exitCode = 2;\n }\n });\n\n cli\n .command(\n 'explain <ruleId>',\n \"Print the rule's severity, category, recommendation, and helpUri\",\n )\n .option('--json', 'Emit structured JSON instead of formatted text')\n .action(async (ruleId: string, flags: ExplainCliFlags) => {\n const doc = loadRuleDoc(ruleId);\n if (!doc) {\n process.stderr.write(\n `nuxt-doctor explain: unknown rule '${ruleId}'. Try \\`nuxt-doctor list-rules\\` to see registered rules.\\n`,\n );\n process.exitCode = 2;\n return;\n }\n if (flags.json) {\n process.stdout.write(`${JSON.stringify(doc, null, 2)}\\n`);\n } else {\n process.stdout.write(renderExplain(doc));\n }\n process.exitCode = 0;\n });\n\n cli\n .command(\n 'inspect [dir]',\n 'Print the detected project capabilities doctor uses to gate rules',\n )\n .option('--json', 'Emit structured JSON instead of formatted text')\n .option('--json-compact', 'With --json, emit a single-line payload')\n .action(async (dir: string | undefined, flags: InspectCliFlags) => {\n const rootDir = resolve(dir ?? '.');\n const project = await detectProject(rootDir);\n if (flags.json || flags.jsonCompact) {\n const payload = projectInfoToJson(project);\n const out = flags.jsonCompact\n ? JSON.stringify(payload)\n : JSON.stringify(payload, null, 2);\n process.stdout.write(`${out}\\n`);\n } else {\n process.stdout.write(renderInspect(project, rootDir));\n }\n process.exitCode = 0;\n });\n\n cli\n .command('init [dir]', 'Scaffold a doctor config for the project')\n .option('-y, --yes', 'Non-interactive, use recommended defaults')\n .option(\n '--config-format <ts|json|package-json>',\n 'Config file format (default: ts)',\n )\n .option('--force', 'Overwrite existing config')\n .option('--dry-run', 'Print what would be written, touch nothing')\n .action(async (dir: string | undefined, flags: InitCliFlags) => {\n try {\n await runInit(dir ?? '.', flags);\n } catch (err) {\n process.stderr.write(`${err instanceof Error ? err.message : err}\\n`);\n process.exitCode = 2;\n }\n });\n\n cli.help();\n cli.version(readVersion());\n cli.parse(argv, { run: false });\n await cli.runMatchedCommand();\n return process.exitCode ?? 0;\n}\n"],"mappings":";;;;;;;;AAsCA,SAAS,cAAsB;CAC7B,IAAI;EACF,MAAM,OAAO,QAAQ,cAAc,OAAO,KAAK,IAAI,CAAC;EAIpD,OAHY,KAAK,MACf,aAAa,QAAQ,MAAM,kBAAkB,EAAE,QAAQ,CAE/C,CAAC,WAAW;SAChB;EACN,OAAO;;;AA8CX,SAAS,kBAA2B;CAClC,MAAM,MAAM,QAAQ;CACpB,OAAO,QACL,IAAI,OAAO,UACX,IAAI,OAAO,OACX,IAAI,mBAAmB,UACvB,IAAI,cAAc,UAClB,IAAI,aAAa,UACjB,IAAI,WAAW,UACf,IAAI,cAAc,UAClB,IAAI,aACL;;AAGH,SAAS,kBAAkB,GAAwC;CACjE,OAAO;EACL,WAAW,EAA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EhC,QAAQ,OAAO,MAAM,cAAc,SAAS,QAAQ,CAAC;EAEvD,QAAQ,WAAW;GACnB;CAEJ,IACG,QAAQ,cAAc,2CAA2C,CACjE,OAAO,aAAa,4CAA4C,CAChE,OACC,0CACA,mCACD,CACA,OAAO,WAAW,4BAA4B,CAC9C,OAAO,aAAa,6CAA6C,CACjE,OAAO,OAAO,KAAyB,UAAwB;EAC9D,IAAI;GACF,MAAM,QAAQ,OAAO,KAAK,MAAM;WACzB,KAAK;GACZ,QAAQ,OAAO,MAAM,GAAG,eAAe,QAAQ,IAAI,UAAU,IAAI,IAAI;GACrE,QAAQ,WAAW;;GAErB;CAEJ,IAAI,MAAM;CACV,IAAI,QAAQ,aAAa,CAAC;CAC1B,IAAI,MAAM,MAAM,EAAE,KAAK,OAAO,CAAC;CAC/B,MAAM,IAAI,mBAAmB;CAC7B,OAAO,QAAQ,YAAY"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@geoql/nuxt-doctor",
3
- "version": "0.1.1",
3
+ "version": "1.0.1",
4
4
  "private": false,
5
5
  "description": "CLI auditor for Nuxt 4 apps. Detects anti-patterns, AI-slop, and best-practice violations via @vue/compiler-sfc + oxlint. Run with `npx -y @geoql/nuxt-doctor`.",
6
6
  "keywords": [
@@ -49,12 +49,14 @@
49
49
  "cac": "^7.0.0",
50
50
  "kolorist": "^1.8.0",
51
51
  "oxlint": "^1.67.0",
52
- "@geoql/doctor-core": "^0.1.1",
53
- "@geoql/oxlint-plugin-nuxt-doctor": "0.1.1",
54
- "@geoql/oxlint-plugin-vue-doctor": "0.1.1"
52
+ "prompts": "^2.4.2",
53
+ "@geoql/doctor-core": "^1.0.1",
54
+ "@geoql/oxlint-plugin-nuxt-doctor": "1.0.0",
55
+ "@geoql/oxlint-plugin-vue-doctor": "1.0.0"
55
56
  },
56
57
  "devDependencies": {
57
58
  "@types/node": "^25.9.1",
59
+ "@types/prompts": "^2.4.9",
58
60
  "@vue/compiler-core": "^3.5.35",
59
61
  "@vue/compiler-sfc": "^3.5.35",
60
62
  "c12": "^4.0.0-beta.5",