agentleFS
huialihuiali/rust-skills/skills/rust-learner/SKILL.md

rust-learner

Skill47 starsChanged 10 months agoMITView on GitHub

Rust learning and ecosystem tracking expert covering version updates, new features, RFC tracking, crate updates, best practice evolution, and learning resources.

2 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    When learning new Rust features:

    line 253

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Version Update Strategy

Stable Updates

# Check current version
rustc --version

# Update Rust
rustup update stable

# View changelog
rustup doc --changelog

When to Upgrade

ScenarioRecommendation
New projectUse latest stable
Production projectFollow 6-week cycle
Library projectConsider MSRV policy

MSRV (Minimum Supported Rust Version)

[package]
rust-version = "1.70"  # Declare minimum version

[dependencies]
# MSRV-sensitive dependencies require care
serde = { version = "1.0", default-features = false }

Solution Patterns

Pattern 1: Following Stable Releases

# Quarterly update routine
rustup update stable
cargo outdated
cargo audit
cargo test --all-features

# Read release notes
rustup doc --changelog

Pattern 2: Tracking Ecosystem Changes

# Check for breaking changes
cargo update --dry-run

# Security audit
cargo audit

# License check
cargo deny check licenses

# Check dependency tree
cargo tree

Pattern 3: Learning New Features

// Edition 2024 features

// Inline const (1.79+)
const fn compute() -> [u8; 32] {
    let mut arr = [0u8; 32];
    // compute at compile time
    arr
}

// Never type improvements (1.82+)
fn diverge() -> ! {
    panic!("never returns")
}

// Async fn in trait (1.75+)
trait Repository {
    async fn fetch(&self, id: u64) -> Result<Data, Error>;
}

Learning Path

Beginner → Advanced

Basics → Ownership, lifetimes, borrow checker
   ↓
Intermediate → Trait objects, generics, closures
   ↓
Concurrency → async/await, threads, channels
   ↓
Advanced → unsafe, FFI, performance optimization
   ↓
Expert → Macros, type system, design patterns

Information Sources

Official Channels

SourceContentFrequency
This Week in RustWeekly digest, RFCs, blogsWeekly
Rust BlogMajor releases, deep divesAs released
Rust RFCsDesign discussionsOngoing
Release NotesVersion changesEvery 6 weeks

Community Resources

ResourceContent
docs.rsDocumentation search
crates.ioPackage search
lib.rsFind alternative crates
Rust AnalyzerIDE plugin

Dependency Management

Regular Updates

# Check outdated dependencies
cargo outdated

# Update compatible versions
cargo update

# Update to latest (may break)
cargo upgrade

Security Audit

# Check for known vulnerabilities
cargo audit

# Check dependency licenses
cargo deny check licenses

# Analyze dependency tree
cargo tree -d  # Show duplicates

Workflow

Quarterly Checklist

Every 3 months:
- [ ] Upgrade to latest stable Rust
- [ ] Run cargo outdated
- [ ] Run cargo audit
- [ ] Check dependencies for breaking changes
- [ ] Evaluate new features worth adopting
- [ ] Update tooling (clippy, rustfmt)

Annual Checklist

Every year:
- [ ] Consider edition upgrade
- [ ] Refactor deprecated patterns
- [ ] Evaluate MSRV policy
- [ ] Update development toolchain
- [ ] Review architecture patterns

Learning Resources

Beginner

Intermediate

Advanced

Practice

Edition Update Strategy

EditionReleasedKey Features
2015Original-
2018Dec 2018Module system, NLL
2021Oct 2021Disjoint captures, IntoIterator
2024TBDGen blocks, async drop

Upgrading Editions

# Check if upgrade possible
cargo fix --edition

# Update Cargo.toml
# edition = "2024"

# Test thoroughly
cargo test --all-features

Review Checklist

When learning new Rust features:

  • Feature is stable (not experimental)
  • Understand the problem it solves
  • Know when NOT to use it
  • Aware of trade-offs
  • Tested in small project first
  • Read release notes thoroughly
  • Checked ecosystem adoption
  • Updated team documentation

Verification Commands

# Check Rust version
rustc --version
rustup show

# Update toolchain
rustup update

# Check outdated dependencies
cargo outdated

# Security audit
cargo audit

# License compliance
cargo deny check

# Check for deprecated features
cargo clippy -- -W deprecated

Common Pitfalls

1. Chasing Shiny Features

Symptom: Using unstable features in production

# ❌ Avoid: nightly features in production
#![feature(generic_associated_types)]

# ✅ Good: wait for stabilization
# Use stable alternatives

2. Ignoring MSRV

Symptom: Breaking downstream users

# ✅ Good: declare MSRV
[package]
rust-version = "1.70"

# Test against MSRV in CI
# cargo +1.70 test

3. Not Reading Release Notes

Symptom: Surprised by breaking changes

# ✅ Good: read before updating
rustup doc --changelog

# Check crate changelogs
cargo info <crate> --version <version>

Related Skills

  • rust-ecosystem - Crate selection and tools
  • rust-coding - Best practices and conventions
  • rust-performance - Performance improvements
  • rust-async - Async/await patterns
  • rust-error - Error handling evolution

Localized Reference

  • Chinese version: SKILL_ZH.md - 完整中文版本,包含所有内容

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.