Skip to content

Derive on structs with generics #173

Derive on structs with generics

Derive on structs with generics #173

Workflow file for this run

name: CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
CARGO_TERM_COLOR: always
jobs:
test-and-lint:
runs-on: ubuntu-latest
strategy:
matrix:
toolchain:
- stable
# - beta
# - nightly
# keep this fixed to the version in rust-toolchain.toml, README.md and below
- nightly-2022-11-03
# - 1.31.0 # find out MSRV
steps:
- uses: actions/checkout@v3
- name: Update toolchain
run: |
rustup default ${{ matrix.toolchain }}
rustup override set ${{ matrix.toolchain }}
rustup component add clippy
- name: Show toolchain info
run: |
cargo --version --verbose
rustc --version
cargo clippy --version
- name: Lint stable
if: ${{ matrix.toolchain == 'stable' }}
run: |
cargo clippy --workspace -- -D warnings
- name: Lint nightly
if: ${{ matrix.toolchain == 'nightly-2022-11-03' }}
run: |
cargo clippy --workspace --features nightly -- -D warnings
- name: Test stable
if: ${{ matrix.toolchain == 'stable' }}
run: |
cargo test --workspace
- name: Test nightly
if: ${{ matrix.toolchain == 'nightly-2022-11-03' }}
run: |
cargo test --workspace --features nightly