← ClaudeAtlas

cargo-workflowslisted

Use when you manage a Rust workspace - add or remove crates, edit workspace dependencies and lints, pin the toolchain, run cargo nextest/audit/deny, configure Cargo profiles and rustflags for cross-compilation to Android or iOS, build cdylib or staticlib FFI artifacts, wire a host build system to cargo, debug Cargo.lock churn or feature-unification surprises, or migrate the crate edition.
po4yka/rust-skills · ★ 2 · AI & Automation · score 76
Install: claude install-skill po4yka/rust-skills
# Cargo Workflows This skill covers the workspace-level mechanics of Cargo: layout, dependency inheritance, profiles, cross-compilation, test runners, supply-chain policy, and edition migration. Run every command from the directory that holds the workspace `Cargo.toml`. ## Workspace layout A multi-crate project uses a virtual manifest at the workspace root. Keep the control files next to it. ```text <workspace-root>/ Cargo.toml # Virtual workspace manifest: members, deps, lints, profiles Cargo.lock # Checked in for an application workspace rust-toolchain.toml # Pinned toolchain + components (rustfmt, clippy) rustfmt.toml # Formatter config clippy.toml # Clippy thresholds (msrv, allowed-duplicate-crates, ...) deny.toml # cargo-deny policy .cargo/config.toml # Per-target rustflags .config/nextest.toml # nextest profiles crates/ <leaf-crates>/ # Pure logic, no internal dependents <mid-layer-crates>/ <ffi-crate>/ # cdylib / staticlib boundary, depends on everything <cli-crate>/ # Host-only binary <bench-crate>/ # Criterion benchmarks ``` Rules: - Do not hardcode the member count in documentation. Derive it with `cargo metadata --locked --no-deps --format-version 1`. - Order the `members` list from leaf crates to the FFI crate. The order records the dependency direction and drives migration order. - Keep helper scripts and fixtu