Review Rust code with rule-cited findings using BeautifulRust
Review a Rust file, crate or diff with scoped tool checks and prioritized findings that cite source rules, locations and concrete fixes.
npx skills add agentskillexchange/skills --skill review-rust-code-with-rule-cited-findings-using-beautifulrust
Use BeautifulRust’s rust-review skill when an agent must review a specified Rust file, crate, module or pull-request diff and return prioritized findings with source rules and concrete fixes. Invoke it when a normal compiler or Clippy run cannot explain API design, soundness, error handling and maintainability tradeoffs in the context of the code.
What this skill actually does
Inputs and setup
Provide the repository and exact review scope. Install the complete upstream skill folders and references as described in the pinned README. The rust-best-practices companion supplies rule references; rust-port is distributed alongside it, but this listing covers the review workflow. Use a coding agent that reads the Agent Skills format. A Rust toolchain and Cargo enable mechanical checks.
Review workflow
- Read the requested scope, Cargo.toml, edition and minimum supported Rust version. State whether the target is a library or application. For a diff, inspect changed lines and consequences rather than expanding automatically to the whole repository.
- When tools are available, run
cargo fmt --check,cargo clippy --all-targets --all-features -- -W clippy::pedantic, andcargo testfrom the crate root. State which checks actually ran; keep tool output separate from conclusions that require judgment. - Inspect correctness and soundness first, followed by error handling, public API design, idiom, documentation and tests. Consult bundled references for uncertain rules and the Bevy reference when appropriate.
- Return Must fix, Should fix and Consider findings, followed by what the code already does well. Each finding identifies a file and line, cites the relevant rule and source, explains the consequence, and shows the smallest proposed change. Group repeated issues and respect documented intentional behavior.
Output and boundary
The deliverable is a proportionate review report for the named scope. Offer concrete fixes without rewriting files unless the user requests implementation. Suggest the upstream lint configuration when relevant rather than installing or changing project policy automatically. Do not claim that checks passed when they were unavailable. This is a reusable Rust review procedure, with review criteria and an output contract, rather than a listing for the Rust language, Clippy or a general coding agent.
Framework: Multi-Framework. Upstream deliberately supports several Agent Skills runtimes; no single runtime is central to this workflow. Metadata and source invocation were inspected, but installation, Rust execution and security review were not performed in this intake.
Sources: pinned review skill and pinned installation documentation.