name: Rust
on: [push, pull_request]
jobs:
run:
name: Run
runs-on: ubuntu-latest
steps:
- name: Install Rust stable
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
components: rustfmt, clippy
override: true
- name: Get sources
uses: actions/checkout@v2
- name: Build
uses: actions-rs/cargo@v1
with:
command: build
args: --workspace
- name: Lint
uses: actions-rs/cargo@v1
with:
command: clippy
args: --workspace -- -D warnings
- name: Test
uses: actions-rs/cargo@v1
with:
command: test
args: --workspace