version: 2 jobs: build: docker: - image: rust:1 steps: - checkout - run: name: Setup environment command: | rustup toolchain install nightly-2020-06-10 rustup default nightly-2020-06-10 rustup component add rustfmt rustup component add clippy rustup update - run: name: Linter command: | cargo fmt --all -- --check cargo clippy -- -D warnings - run: name: Build command: cargo build - run: name: Unit tests command: cargo test