mirror of
https://github.com/abhigyanpatwari/GitNexus.git
synced 2026-10-09 03:17:54 +00:00
fix(cli): translate Commander --no-stats into noStats option (#704)
Commander's negatable-boolean convention sets options.stats = false when --no-stats is passed, not options.noStats = true. The three call sites that forward CLI options into runFullAnalysis / generateAIContextFiles read options.noStats, so the flag was silently ignored and symbol counts always got written into AGENTS.md / CLAUDE.md. Fix: add ?? (options?.stats === false) fallback at all three call sites.
This commit is contained in:
parent
5b1966c2ca
commit
83b9a268e3
2 changed files with 3 additions and 3 deletions
|
|
@ -228,7 +228,7 @@ export const analyzeCommand = async (inputPath?: string, options?: AnalyzeOption
|
|||
embeddings: options?.embeddings,
|
||||
skipGit: options?.skipGit,
|
||||
skipAgentsMd: options?.skipAgentsMd,
|
||||
noStats: options?.noStats,
|
||||
noStats: options?.noStats ?? (options?.stats === false),
|
||||
registryName: options?.name,
|
||||
// Registry-collision bypass — its own CLI flag, intentionally NOT
|
||||
// overloading --force. A user who hits the collision guard should
|
||||
|
|
@ -298,7 +298,7 @@ export const analyzeCommand = async (inputPath?: string, options?: AnalyzeOption
|
|||
processes: s.processes,
|
||||
},
|
||||
skillResult.skills,
|
||||
{ skipAgentsMd: options?.skipAgentsMd, noStats: options?.noStats },
|
||||
{ skipAgentsMd: options?.skipAgentsMd, noStats: options?.noStats ?? (options?.stats === false) },
|
||||
);
|
||||
}
|
||||
} catch {
|
||||
|
|
|
|||
|
|
@ -379,7 +379,7 @@ export async function runFullAnalysis(
|
|||
processes: pipelineResult.processResult?.stats.totalProcesses,
|
||||
},
|
||||
undefined,
|
||||
{ skipAgentsMd: options.skipAgentsMd, noStats: options.noStats },
|
||||
{ skipAgentsMd: options.skipAgentsMd, noStats: options.noStats ?? (options.stats === false) },
|
||||
);
|
||||
} catch {
|
||||
// Best-effort — don't fail the entire analysis for context file issues
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue