Global Rank · of 600 Skills
rust-skills AI Agent Skill
View Source: leonardomso/rust-skills
CriticalInstallation
npx skills add leonardomso/rust-skills --skill rust-skills 453
Installs
Rust Skills
179 Rust rules your AI coding agent can use to write better code.
Works with Claude Code, Cursor, Windsurf, Copilot, Codex, Aider, Zed, Amp, Cline, and pretty much any other agent that supports skills.
Install
npx add-skill leonardomso/rust-skillsThat's it. The CLI figures out which agents you have and installs the skill to the right place.
How to use it
After installing, just ask your agent:
/rust-skills review this function/rust-skills is my error handling idiomatic?/rust-skills check for memory issuesThe agent loads the relevant rules and applies them to your code.
What's in here
179 rules split into 14 categories:
| Category | Rules | What it covers |
|---|---|---|
| Ownership & Borrowing | 12 | When to borrow vs clone, Arc/Rc, lifetimes |
| Error Handling | 12 | thiserror for libs, anyhow for apps, the ? operator |
| Memory | 15 | SmallVec, arenas, avoiding allocations |
| API Design | 15 | Builder pattern, newtypes, sealed traits |
| Async | 15 | Tokio patterns, channels, spawn_blocking |
| Optimization | 12 | LTO, inlining, PGO, SIMD |
| Naming | 16 | Following Rust API Guidelines |
| Type Safety | 10 | Newtypes, parse don't validate |
| Testing | 13 | Proptest, mockall, criterion |
| Docs | 11 | Doc examples, intra-doc links |
| Performance | 11 | Iterators, entry API, collect patterns |
| Project Structure | 11 | Workspaces, module layout |
| Linting | 11 | Clippy config, CI setup |
| Anti-patterns | 15 | Common mistakes and how to fix them |
Each rule has:
- Why it matters
- Bad code example
- Good code example
- Links to official docs when relevant
Manual install
If add-skill doesn't work for your setup, here's how to install manually:
Claude Code
Global (applies to all projects):
git clone https://github.com/leonardomso/rust-skills.git ~/.claude/skills/rust-skillsOr just for one project:
git clone https://github.com/leonardomso/rust-skills.git .claude/skills/rust-skillsOpenCode
git clone https://github.com/leonardomso/rust-skills.git .opencode/skills/rust-skillsCursor
git clone https://github.com/leonardomso/rust-skills.git .cursor/skills/rust-skillsOr just grab the skill file:
curl -o .cursorrules https://raw.githubusercontent.com/leonardomso/rust-skills/master/SKILL.mdWindsurf
mkdir -p .windsurf/rules
curl -o .windsurf/rules/rust-skills.md https://raw.githubusercontent.com/leonardomso/rust-skills/master/SKILL.mdOpenAI Codex
git clone https://github.com/leonardomso/rust-skills.git .codex/skills/rust-skillsOr use the AGENTS.md standard:
curl -o AGENTS.md https://raw.githubusercontent.com/leonardomso/rust-skills/master/SKILL.mdGitHub Copilot
mkdir -p .github
curl -o .github/copilot-instructions.md https://raw.githubusercontent.com/leonardomso/rust-skills/master/SKILL.mdAider
Add to .aider.conf.yml:
read: path/to/rust-skills/SKILL.mdOr pass it directly:
aider --read path/to/rust-skills/SKILL.mdZed
curl -o AGENTS.md https://raw.githubusercontent.com/leonardomso/rust-skills/master/SKILL.mdAmp
git clone https://github.com/leonardomso/rust-skills.git .agents/skills/rust-skillsCline / Roo Code
mkdir -p .clinerules
curl -o .clinerules/rust-skills.md https://raw.githubusercontent.com/leonardomso/rust-skills/master/SKILL.mdOther agents (AGENTS.md)
If your agent supports the AGENTS.md standard:
curl -o AGENTS.md https://raw.githubusercontent.com/leonardomso/rust-skills/master/SKILL.mdAll rules
See SKILL.md for the full list with links to each rule file.
Where these rules come from
- Rust API Guidelines
- Rust Performance Book
- Rust Design Patterns
- Real code from ripgrep, tokio, serde, polars, axum
- Clippy docs
Contributing
PRs welcome. Just follow the format of existing rules.
License
MIT
Installs
Security Audit
View Source
leonardomso/rust-skills
More from this source
Power your AI Agents with
the best open-source models.
Drop-in OpenAI-compatible API. No data leaves Europe.
Explore Inference APIGLM
GLM 5
$1.00 / $3.20
per M tokens
Kimi
Kimi K2.5
$0.60 / $2.80
per M tokens
MiniMax
MiniMax M2.5
$0.30 / $1.20
per M tokens
Qwen
Qwen3.5 122B
$0.40 / $3.00
per M tokens
How to use this skill
Install rust-skills by running npx skills add leonardomso/rust-skills --skill rust-skills in your project directory. Run the install command above in your project directory. The skill file will be downloaded from GitHub and placed in your project.
No configuration needed. Your AI agent (Claude Code, Cursor, Windsurf, etc.) automatically detects installed skills and uses them as context when generating code.
The skill enhances your agent's understanding of rust-skills, helping it follow established patterns, avoid common mistakes, and produce production-ready output.
What you get
Skills are plain-text instruction files — not executable code. They encode expert knowledge about frameworks, languages, or tools that your AI agent reads to improve its output. This means zero runtime overhead, no dependency conflicts, and full transparency: you can read and review every instruction before installing.
Compatibility
This skill works with any AI coding agent that supports the skills.sh format, including Claude Code (Anthropic), Cursor, Windsurf, Cline, Aider, and other tools that read project-level context files. Skills are framework-agnostic at the transport level — the content inside determines which language or framework it applies to.
Chat with 100+ AI Models in one App.
Use Claude, ChatGPT, Gemini alongside with EU-Hosted Models like Deepseek, GLM-5, Kimi K2.5 and many more.