Expand description
Per-command lib API for rs-hack subcommands.
Each module exposes pub fn run(args: …Args) -> Result<…Result> so embedders (MCP server,
yah, tests) can drive the same logic without shelling out. The CLI in main.rs is a thin
clap → struct → run() translator that adds rendering on top.
Modules§
- comments
commentscommand: list every comment span in a set of files, apply a hash-guarded batch of delete/replace edits to them, and verify that code is unchanged once comments are ignored.- doc_
coverage doc-coveragecommand: report missing doc-comments for public items.- find
findcommand as a lib API. Returns structured matches; rendering (text, snippets, hints) is the caller’s job — seemain.rsfor the CLI renderer.- match_
audit match-auditcommand: detect match expressions that are missing enum variants.- neighbors
neighborscommand: pure filesystem discovery of related files. No AST parsing — finds siblings, twin dirs, and test files for any .rs file.- summary
summarycommand: print a module inventory for a single .rs file.