rust-crate-selection

Recommends Rust crates by domain and manages Cargo.toml versions and features.

Updated Mar 29, 2026
One-click install
npx skills add https://github.com/luckyegg168/rust-skill --skill rust-crate-selection-luckyegg168
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: rust-crate-selection
Source: https://github.com/luckyegg168/rust-skill/tree/main/rust-skills/rust-crate-selection
Command: npx skills add https://github.com/luckyegg168/rust-skill --skill rust-crate-selection-luckyegg168

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Choosing the right Rust crate among many similar options is time-consuming and risky, and misconfigured Cargo.toml dependencies cause version conflicts, bloated compile times, and feature-gating errors. This Skill provides curated crate recommendations across 12 domains plus concrete guidance on version pinning and feature management. ## Core Features & Use Cases - Domain-based crate recommendations: Curated tables for web frameworks (axum, actix-web), HTTP clients (reqwest, hyper), serialization (serde), CLI (clap), logging (tracing), databases (sqlx, diesel), async (tokio), testing (proptest, criterion), GUI (egui, tauri), and more, with current stable versions. - Version locking and features management: SemVer syntax guidance, Cargo.lock commit strategy by project type, minimal-features patterns with default-features = false, and optional dependency wiring via feature flags. - Error troubleshooting: A lookup table mapping common Cargo errors (duplicate crate versions, yanked packages, missing features, MSRV mismatches) to their fixes. - Use Case: When starting a new web API project, ask for a recommended dependency stack and receive a complete Cargo.toml template with axum, tokio, sqlx, tracing, and serde configured with correct features. ## Quick Start Ask the AI to recommend Rust crates and generate a Cargo.toml dependency configuration for your project type, such as a web API server, CLI tool, or library crate.

Frequently Asked Questions about rust-crate-selection

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I choose the right Rust crate for my project?▼

Evaluate crates on five criteria: crates.io download volume and trend, maintenance activity, documentation quality on docs.rs, idiomatic API design, and dependency tree depth checked with cargo tree. Also verify MSRV compatibility and license terms.

What Rust crate should I use for HTTP requests?▼

reqwest 0.12 is the most widely used HTTP client, supporting both async and blocking modes. Use hyper 1.5 for low-level control, or ureq 3.0 for pure blocking CLI tools without async dependencies.

axum vs actix-web: which Rust web framework is better?▼

axum 0.8 is maintained by the tokio team with type-safe routing and the tower middleware ecosystem. actix-web 4.9 is a mature multi-threaded framework focused on performance. Choose axum for tokio ecosystem integration.

Should Cargo.lock be committed to version control?▼

Applications and workspaces should commit Cargo.lock to ensure reproducible builds. Library crates should not commit it, letting downstream consumers resolve their own dependency versions.

Why does my Rust build fail with two different versions of a crate?▼

This happens when the dependency tree contains multiple incompatible versions of the same crate. Run cargo tree -d to find duplicates, then unify versions or use a [patch] section in Cargo.toml to override.

How do I reduce Rust compile time from heavy dependencies?▼

Set default-features = false and enable only the features you need for each dependency. Use cargo build --timings to identify bottlenecks and cargo deny to audit dependency chain depth.