Skip to content

Releases: morganlinton/BeautifulRust

v1.4.0: every rule, checked

Choose a tag to compare

@morganlinton morganlinton released this 26 Oct 02:27

The first BeautifulRust release with outside contributions. Huge thanks to @mvanhorn, who sent both of this release's headline features.

Every lint is now proven to fire

lints/check/ is a small crate with one deliberate violation for each of the 28 lints in the drop-in config, and scripts/check-lints.sh runs clippy on it. It fails if a lint goes quiet, if anything unexpected fires, or if the published table drifts from the tested one. CI runs it on every push and pull request, so the lints config can't silently rot.

It already caught a real problem: clippy silently disables allow_attributes and allow_attributes_without_reason for any crate whose rust-version is below 1.81, because those crates can't use #[expect]. If your MSRV is older, those two lints were never on. The config and README now say so.

The skills are checked in CI

scripts/check-skill.py validates every skill's frontmatter and links, every eval case, and the plugin manifests, using only Python's standard library. It runs on every push and pull request, so a broken skill can't ship.

Also

  • Four more lints: redundant_clone, rc_buffer, string_add, and wildcard_imports.
  • rust-best-practices is back under the 500-line skill guidance, with no rules removed.
  • CI uses actions/checkout@v7 with read-only permissions.

Full details are in the changelog. Update a Claude Code install with claude plugin update beautiful-rust; for other agents, re-run your install command.

Want to contribute? CONTRIBUTING.md has the one rule: every rule needs a published source.

v1.3.0: port your code to Rust

Choose a tag to compare

@morganlinton morganlinton released this 26 Oct 00:32

BeautifulRust now ports existing code to Rust, and the repo is ready for contributors.

New: the rust-port skill

Ask your agent to port a module ("port parser.c to Rust", "rewrite this Python service in Rust") and it:

  • reads the original and its tests, and ports the tests first, so the port is proven against the original's own behavior
  • designs a Rust API instead of transliterating: NULL and None become Option, error codes and exceptions become an error enum, out-parameters become return values, flag ints and magic strings become typed values, and dict insertion order becomes an ordered collection instead of a HashMap that would silently reorder output
  • keeps the port proportionate: it uses Rust's standard library rather than reimplementing the source language's string and number handling, and documents exotic differences instead of coding around them
  • verifies with cargo test and clippy, and writes a PORTING.md mapping the old API and tests to the new ones, with every deliberate difference listed

It covers C, C++, Python, Go, JavaScript, and TypeScript.

How it tested

Ported a C config parser and a Python task scheduler, each with its original test suite, with and without the skill:

With skill Without
Checks passed 22 of 22 19 of 22
Python port size vs. original 3.1x 5.8x
Reimplemented Python's string and number semantics No Yes

Without the skill, the model already ports correctly: every port built, passed its tests, and was clippy-clean, and both C ports matched the original byte for byte on 20 tricky inputs. The skill's contribution is restraint. Without it, the Python port hand-copied splitlines, strip, int(), and repr() and grew a dozen extra public methods. One run per configuration.

New: contributor guidelines

CONTRIBUTING.md centers on one rule: every rule needs a published source. There are issue templates for proposing a rule and for reporting a review false positive, which become new eval cases.

Full details are in the changelog. Update a Claude Code install with claude plugin update beautiful-rust; for other agents, re-run your install command.

v1.2.0: review your Rust, not just write it

Choose a tag to compare

@morganlinton morganlinton released this 25 Oct 11:48

BeautifulRust now reviews existing code, not just new code, and ships lints to keep the rules enforced.

New: the rust-review skill

Point your agent at a file, crate, or diff ("review src/parser.rs") and it writes a prioritized report: must fix, should fix, and consider. Every finding gives a file:line location, the rule it breaks with its source (an API Guidelines code like C-GETTER, an Effective Rust item, a Microsoft guideline, or a clippy lint), and the smallest code change that fixes it. It runs fmt, clippy, and tests when Rust is installed, and every report ends with what the code already does well.

Tested on a deliberately messy module, with and without the skill:

With skill Without
Checks passed 11 of 12 7 of 12
Findings citing a named rule 13 of 13 2 of 20
Findings with a code fix 13 of 13 0 of 20

See examples/review-inventory.md for the unedited report.

New: drop-in lints

lints/ has a [lints] block for Cargo.toml and a clippy.toml that make clippy enforce the machine-checkable rules: no unwrap() outside tests, a // SAFETY: comment on every unsafe block, a reason on every suppression, no bool parameters, and no silent lossy casts. Every lint was checked against clippy 0.1.99.

Also

  • Every Rust example in the skills, references, and README now compiles on stable Rust 1.99.
  • Install instructions for Claude Code, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, and npx skills. Both skills are standard Agent Skills.
  • A new painted banner.

Full details are in the changelog.

Update an existing Claude Code install with claude plugin update beautiful-rust. For other agents, re-run your install command.

v1.1.0

Choose a tag to compare

@morganlinton morganlinton released this 24 Oct 14:17

The skill was tested against three realistic Rust tasks with and without it loaded, graded by independent agents on 30 concrete assertions, and tightened where the first round showed gaps. Result: 29 of 30 with the skill versus 24 of 30 without, up from 25 of 26 versus 23 of 26 before the changes.

Skill changes

  • bool parameters are now out of public and shared signatures, full stop. Use a two-variant enum or two methods. An existing bool is a smell to remove when refactoring.
  • New section on refactoring someone else's code: fix every smell on the list, keep public behavior identical unless the change is the point, show before and after for any signature you change, and flag quirks instead of silently fixing them.
  • A hand-written Ord must come with matching PartialEq and Hash.

Eval cases

skills/rust-best-practices/evals/ now holds the three test cases (library API design, application CLI, refactor with an input file) in the layout claude plugin eval reads. See the README's Testing section.

Update with:

claude plugin update beautiful-rust

v1.0.0

Choose a tag to compare

@morganlinton morganlinton released this 24 Oct 00:40

First release of Beautiful Rust, a Claude Code plugin with one skill, rust-best-practices, that teaches Claude to write idiomatic, robust Rust.

The skill distills five sources into a ~500-line guide Claude loads whenever a task involves Rust, with a condensed digest of each source bundled for deeper lookups: the Google Rust Style Guide, the Rust API Guidelines, Effective Rust, Rust Design Patterns, and Microsoft's Pragmatic Rust Guidelines.

Install:

claude plugin install beautiful-rust --marketplace morganlinton/BeautifulRust