Simple Basic Rust Examples
It's assumed that Rust is configured and running.
Compile and execute unit, integration, and documentation tests.
cargo test
Build the documentation for the local package and all dependencies. The output is placed in target/doc.
cargo doc
Compile local packages and all of their dependencies.
cargo build
Execute the compiled code.
./target/debug/basic-rust --dev
Remove artifacts from the target directory that Cargo has generated in the past.
cargo clean
References:
The Cargo Book
The Rust Programming Language
rustlings