Merge pull request #351 from ysndr/patch-2 #570
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
pull_request: | |
push: | |
branches: | |
- master | |
name: Check and Lint | |
jobs: | |
windows: | |
name: Tests on windows | |
runs-on: windows-latest | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v3 | |
- name: Install rust toolchain | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
toolchain: stable | |
- name: Tests | |
run: cargo test -p bpaf -p bpaf_derive --all-targets --all-features --no-fail-fast | |
linux: | |
name: Tests, formatting and clippy on linux | |
runs-on: ubuntu-latest | |
env: | |
RUSTDOCFLAGS: -Dwarnings | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v3 | |
- name: Install rust toolchain | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
toolchain: stable | |
components: rustfmt clippy | |
- name: clippy minimal features | |
run: cargo clippy --workspace --all-targets --no-default-features | |
- name: clippy default features | |
run: cargo clippy --workspace --all-targets | |
- name: clippy all features | |
run: cargo clippy --workspace --all-targets --all-features | |
- name: test minimal features | |
run: cargo test -p bpaf -p bpaf_derive --all-targets --no-default-features --no-fail-fast | |
- name: test default features | |
run: cargo test -p bpaf -p bpaf_derive --all-targets --no-fail-fast | |
- name: test all features | |
run: cargo test -p bpaf -p bpaf_derive --all-targets --all-features --no-fail-fast | |
- name: Example documentation | |
run: cargo build --all-features -p docs2 && git diff && git diff-index --quiet HEAD -- | |
- name: Rustdoc | |
env: | |
RUSTDOCFLAGS: -D warnings | |
run: cargo doc --all --no-deps --all-features | |
- name: formatting | |
run: cargo fmt --all -- --check | |
compat: | |
name: Tests on linux with 1.56 toolchain | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v3 | |
- name: Install rust toolchain | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
toolchain: 1.56 | |
- name: test minimal features | |
run: cargo run --manifest-path legacy/Cargo.toml -- --help |