Rust Learning Log

Cargo Workflow Reminders I Want Handy

A small set of cargo commands and habits that make the early Rust workflow feel less clumsy.

Topic: Tooling Status: Reference note cargoworkflowtooling

This one is less a lesson and more a note to future me.

Commands worth remembering

cargo new hello-rust
cargo run
cargo check
cargo test
cargo fmt
cargo clippy

What clicked

  • cargo check is the one I should reach for constantly because it is fast and catches the structural mistakes early.
  • cargo fmt and cargo clippy feel less optional in Rust than they do in a lot of other ecosystems.
  • Cargo makes the workflow feel like a system instead of a bag of disconnected commands.

Rule for myself

If I am confused, reduce the example, run cargo check, and make the compiler complain about the smallest possible thing.

Back to Rust log