name: Build
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
workflow_dispatch:
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
persist-credentials: false fetch-depth: 0 - name: Install Rust
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
override: true
components: rustfmt, clippy
- name: Lint (fmt)
run: cargo fmt --check
- name: Lint (clippy)
run: cargo clippy -- -D warnings
- name: Install cargo-hack
run: cargo install cargo-hack
- name: Test (feature power-set)
run: cargo hack test --feature-powerset