rust
БесплатноБез исполняемых скриптовНе проверенRust engineering standards and deep references — ownership/borrowing-driven design, error handling (thiserror/anyhow), async with tokio, axum services…
от olehsvyrydov★ 18 звёзд на GitHubОб этом скилле
Rust (language skill)
This is a knowledge skill, not an agent: it loads from context whenever Rust is written or reviewed, and the role agents (/be, /rev, /arch) route into it for the language-level rules.
It carries the standards inline; the deep material lives in references/ and is loaded on demand.
Trigger
Use this skill when:
- Writing, editing, or reviewing
.rsfiles - Changing
Cargo.tomlorCargo.lock— dependencies, features, lints, workspace layout - Diagnosing a
cargoorclippyfailure - Designing a Rust component — crate boundaries, error surface, async topology
- Planning tests for Rust code
- Adding a dependency to a Rust workspace
Do NOT load it for merely running or installing a compiled Rust tool — that is an operations task, not a Rust task.
Context
This skill exists to make Rust reviews boring. Invariants live in types, so the compiler argues about them instead of the reviewer. Failure paths are enumerated before code is written, so error handling is a table being filled in, not an improvisation. Policy — toolchain, lints, formatting, dependency rules, coverage — lives in checked-in files, not in anyone's head, so "what does this repo require?" has exactly one answer. The two goals behind every rule here: predictable consequences and cheap extension.
Documentation Lookup (MANDATORY)
Before implementing any feature, check current documentation. Rust ships a new stable release every six weeks and several load-bearing crates are pre-1.0; recall is not a source.
Context7 MCP
Use Context7 MCP to retrieve up-to-date documentation for any crate or tool:
- Resolve library: Call
mcp__context7__resolve-library-idwith the crate name - Query docs: Call
mcp__context7__query-docswith the resolved library ID and your question
When to use: tokio primitives, axum extractors/routing/middleware, rusqlite API, serde attributes, clap derive, proptest strategies.
Example queries:
- "tokio JoinSet and graceful shutdown"
- "axum 0.8 State extractor and middleware ordering"
- "rusqlite transactions and prepared statement caching"
- "thiserror 2 derive attributes and #[from]"
- "clap 4 derive subcommands and value parsing"
- "proptest strategies for recursive data"
Web Research
Use WebSearch and WebFetch for anything version- or advisory-shaped:
| Question | Source to check |
|---|---|
| What changed in a stable Rust release | releases.rs / the official release notes |
| Which clippy lints are new or renamed at a version | the clippy lint list for that exact version |
| Is there an advisory against this crate | the RUSTSEC advisory database |
| What is the current version of a crate | its repository / registry page, at task time |
Rust-specific lookup rules
- Toolchain bumps read the notes first. When bumping the pinned toolchain, read the
release notes and the new clippy lints for the target version (releases.rs is the
fastest index) before editing
rust-toolchain.toml. New deny-by-default behaviour arrives with the compiler; meeting it in CI is not reading. - Pre-1.0 UI frameworks are looked up, never recalled. Frameworks below 1.0 change APIs between minor versions. Look their APIs up against the framework's own repository at task time — current examples tree, current migration notes. This skill deliberately encodes none of their API surface, because anything written here would be wrong within two releases.
Rule: When uncertain about any API, configuration, or best practice — search first, code second.
Versions
| Technology | Version | Notes |
|---|---|---|
| Rust (stable) | 1.97.0 (2026-07-09) | Pin exactly in rust-toolchain.toml — see references/toolchain-and-lints.md |
| Edition | 2024 | The baseline; available since Rust 1.85 |
Cargo [lints] |
stable since Cargo 1.74 | Workspace-level lint severities in the manifest |
| clippy.toml | test allowances | allow-unwrap-in-tests, allow-expect-in-tests, allow-panic-in-tests |
| tokio | 1.x | Async runtime; the lockfile pins the minor |
| thiserror | 2 | Error derives for library crates |
| anyhow | 1 | Error type for binary boundaries only |
| axum | 0.8 | HTTP services; pre-1.0 — re-check APIs at task time |
| rusqlite | 0.40 | Embedded SQLite; bundled implications in references/dependencies-supply-chain.md |
| clap | 4 | CLI argument parsing (derive) |
| rand | 0.9 | OS entropy via TryRngCore (OsRng.try_fill_bytes); 0.8's infallible OsRng.fill_bytes is gone |
| proptest | 1 | Property-based testing |
| cargo-deny, cargo-audit, cargo-llvm-cov, cargo-machete | current | Supply chain, advisories, coverage, unused deps |
Volatility note. Versions above are current as of Aug 2026 — re-verify before pinning. Rust itself moves every six weeks; the pre-1.0 crates move faster.
The Doctrine — ten standards (BLOCKING at review)
Each standard is one sentence of rule,
Установить rust в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл rust?
Rust engineering standards and deep references — ownership/borrowing-driven design, error handling (thiserror/anyhow), async with tokio, axum services, testing, and clippy/cargo-deny discipline. Load whenever writing, editing, or reviewing Rust: any .rs file, Cargo.toml/Cargo.lock change, cargo or clippy failure, or Rust design/test planning — with or without a role agent (/be, /rev) invoked. NOT for merely running or installing a compiled Rust tool.
Как установить скилл rust?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл rust запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
doc-coauthoring
Guide users through a structured workflow for co-authoring documentation. Use when user wants to write documentation, proposals, technical specs, decision…
от Anthropicacademy-guide
Stop and check this skill before finishing any reply to a question about how to use Claude or a Claude product — it recommends matching courses, tutorials…
от Anthropicinternal-comms
A set of resources to help me write all kinds of internal communications, using the formats that my company likes to use. Claude should use this skill…
от Anthropicskill-development
This skill should be used when the user wants to "create a skill", "add a skill to plugin", "write a new skill", "improve skill description", "organize skill…
от Anthropic