bash
mkdir lib-hello && cd lib-hello
cargo init --name trait_exerci --lib
bash
vi Cargo.toml
vi src/lib.rs
cargo fmt
cargo clippy # warning: struct is never constructed: `MyType`
mkdir tests
touch tests/hello.rs
vi tests/hello.rs
touch tests/mod_hello.rs
vi tests/mod_hello.rs
cargo fmt
cargo clippy
cargo test
bash
mkdir examples
touch examples/hello.rs
vi examples/hello.rs
cargo run --example hello