mirror of https://github.com/zkat/cacache-rs.git
meta(ci): improve CI workflow
This commit is contained in:
parent
513d55833d
commit
a746fc0216
|
|
@ -2,12 +2,33 @@ name: Rust
|
|||
|
||||
on: [push, pull_request]
|
||||
|
||||
env:
|
||||
RUSTFLAGS: -Dwarnings
|
||||
|
||||
jobs:
|
||||
build:
|
||||
fmt_and_docs:
|
||||
name: Check fmt & build docs
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: Install Rust
|
||||
uses: actions-rs/toolchain@v1
|
||||
with:
|
||||
profile: minimal
|
||||
toolchain: stable
|
||||
components: rustfmt
|
||||
override: true
|
||||
- name: rustfmt
|
||||
run: cargo fmt --all -- --check
|
||||
- name: docs
|
||||
run: cargo doc
|
||||
|
||||
build_and_test:
|
||||
name: Build & Test
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
matrix:
|
||||
rust: [stable, beta, nightly]
|
||||
rust: [1.39.0, stable]
|
||||
os: [ubuntu-latest, macOS-latest, windows-latest]
|
||||
|
||||
steps:
|
||||
|
|
@ -17,12 +38,10 @@ jobs:
|
|||
with:
|
||||
profile: minimal
|
||||
toolchain: ${{ matrix.rust }}
|
||||
components: rustfmt, clippy
|
||||
components: clippy
|
||||
override: true
|
||||
- name: Check
|
||||
run: cargo check
|
||||
- name: Rustfmt
|
||||
run: cargo fmt --all -- --check
|
||||
- name: Clippy
|
||||
run: cargo clippy -- -D warnings
|
||||
- name: Run tests
|
||||
|
|
|
|||
Loading…
Reference in New Issue