Skip to content

ci

ci #1368

Workflow file for this run

name: ci
on:
pull_request:
push:
branches:
- master
schedule:
- cron: '00 01 * * *'
jobs:
test:
name: test
runs-on: ${{ matrix.os }}
strategy:
matrix:
build:
- pinned
- pinned-win
- stable
- beta
- nightly
- macos
- win-msvc
- win-gnu
include:
- build: pinned
os: ubuntu-latest
rust: 1.34.0
- build: pinned-win
os: windows-latest
rust: 1.34.0
- build: stable
os: ubuntu-latest
rust: stable
- build: beta
os: ubuntu-latest
rust: beta
- build: nightly
os: ubuntu-latest
rust: nightly
- build: macos
os: macos-latest
rust: stable
- build: win-msvc
os: windows-latest
rust: stable
- build: win-gnu
os: windows-latest
rust: stable-x86_64-gnu
steps:
- name: Checkout repository
uses: actions/checkout@v1
with:
fetch-depth: 1
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust }}
override: true
profile: minimal
- run: cargo build --verbose
- run: cargo doc --verbose
- if: startsWith(matrix.build, 'pinned-') == false
run: cargo test --verbose
- if: matrix.build == 'nightly'
run: |
set -x
cargo generate-lockfile -Z minimal-versions
cargo build --verbose
cargo test --verbose
rustfmt:
name: rustfmt
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v1
with:
fetch-depth: 1
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
components: rustfmt
- name: Install rustfmt
run: rustup component add rustfmt
- name: Check formatting
run: |
cargo fmt --all -- --check