Slim down init/scan CLI flags#34
Merged
Merged
Conversation
Reduce the option surface on two commands: whygraph init (7 flags -> 3: --agent, --force, --yes) - Drop --list-agents; the supported-agents list now renders in `whygraph init --help` via a no-rewrap epilog. - Drop --print entirely (flag + docstring mentions); the manual-merge path survives for user-scoped agents via render_snippet(). - Drop --install-assets/--no-install-assets; assets always install (still --force-gated for overwrite). - Drop --skip-preflight; preflight diagnostics always run. whygraph scan - Rename --no-llm-descriptions -> --skip-analyze (same behavior), propagated to the git-hook helper, MCP/analyze comments, CLAUDE.md, and the docs site. Tests updated (incl. rename of the scan flag test file); full suite, ruff check, and ruff format --check all pass.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Reduces the CLI option surface on two commands, removing flags whose behavior is better served by defaults or
--help.whygraph init— 7 flags → 3 (--agent,--force,--yes)--list-agentswhygraph init --help(a no-rewrap epilog)--printagents.pydocstring mentions. The manual-merge path still exists for user-scoped agents viarender_snippet()--install-assets / --no-install-assets--force-gated for overwrite)--skip-preflightwhygraph scan--no-llm-descriptions→--skip-analyze(same behavior). Propagated in lockstep to the git-hook helper (hooks.py), the MCP/analyze comments,CLAUDE.md, and the docs site.Why
--list-agents/--printduplicate information that belongs in--help/docs;--install-assets/--skip-preflightonly existed to opt out of behavior that should always happen.--no-llm-descriptionswas a mouthful —--skip-analyzereads better.Verification
uv run pytest— 525 passing (incl. rename of the scan flag test file totest_cli_scan_skip_analyze.py)uv run ruff check src/ tests/— cleanuv run ruff format --check src/ tests/— cleaninit --agent clauderuns preflight, writes.mcp.json, and copies all.claude/assets with no opt-out flag;scan --helpshows--skip-analyze, old flag gone.--printis the unrelated externalclaude --printCLI).Note
No backward-compat alias for
--no-llm-descriptions— every caller is in-repo and updated here, and WhyGraph is pre-1.0.