Skip to content

clean up ci

clean up ci #165

Workflow file for this run

on: [push, pull_request]
name: CI
jobs:
rustfmt:
name: "Rustfmt (${{ matrix.crate && matrix.crate || 'base' }})"
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: true
matrix:
config:
- { os: ubuntu-latest, target: 'x86_64-unknown-linux-gnu' }
crate: [null, "derive"]
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.config.target }}
override: true
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --check
clippy:
name: "Clippy (${{ matrix.crate && matrix.crate || 'base' }})"
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- { os: ubuntu-latest, target: 'x86_64-unknown-linux-gnu' }
crate: [null, "derive"]
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.config.target }}
override: true
- uses: actions-rs/cargo@v1
with:
command: clippy
args: ${{ matrix.crate && format(' --manifest-path {0}/Cargo.toml', matrix.crate) }}
test_all:
name: TestAll
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- { os: ubuntu-latest, target: 'x86_64-unknown-linux-gnu' }
- { os: macos-latest, target: 'x86_64-apple-darwin' }
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.config.target }}
override: true
- uses: actions-rs/cargo@v1
with:
command: test
args: --all-features
test_backends:
name: TestBackends
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- { os: ubuntu-latest, target: 'x86_64-unknown-linux-gnu' }
- { os: macos-latest, target: 'x86_64-apple-darwin' }
backend: ["syn", ""]
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.config.target }}
override: true
- uses: actions-rs/cargo@v1
with:
command: test
args: --features "debug_asserts, rustc_hash, generated_setters, debug_diffs, serde, nanoserde, ${{ matrix.backend }}"
test_serde:
name: TestSerde
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- { os: ubuntu-latest, target: 'x86_64-unknown-linux-gnu' }
- { os: macos-latest, target: 'x86_64-apple-darwin' }
backend: ["syn", null]
serde: ["nanoserde", "serde", null]
debug_asserts: ["debug_asserts", null]
debug_diffs: ["debug_diffs", null]
hash: ['rustc_hash', null]
generated_setters: ["generated_setters", null]
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.config.target }}
override: true
- uses: actions-rs/cargo@v1
with:
command: test
args: format('{0}', join([matrix.backend, matrix.serde, matrix.debug_asserts, matrix.debug_diffs, matrix.hash, matrix.generated_setters]))
test_setters:
name: TestSetters
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- { os: ubuntu-latest, target: 'x86_64-unknown-linux-gnu' }
- { os: macos-latest, target: 'x86_64-apple-darwin' }
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.config.target }}
override: true
- uses: actions-rs/cargo@v1
with:
command: test
args: --features generated_setters
test_min:
name: TestMin
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- { os: ubuntu-latest, target: 'x86_64-unknown-linux-gnu' }
- { os: macos-latest, target: 'x86_64-apple-darwin' }
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.config.target }}
override: true
- uses: actions-rs/cargo@v1
with:
command: test
build_release:
name: BuildRelease
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- { os: ubuntu-latest, target: 'x86_64-unknown-linux-gnu' }
- { os: macos-latest, target: 'x86_64-apple-darwin' }
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.config.target }}
override: true
- uses: actions-rs/cargo@v1
with:
command: build
args: --release --all-features