Skip to content

Improve Actions workflow #181

Improve Actions workflow

Improve Actions workflow #181

Workflow file for this run

on:
pull_request:
push:
branches:
- master
name: CI
jobs:
ci:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: KyleMayes/install-llvm-action@v2
if: matrix.os == 'windows-latest'
with:
version: "18.1"
directory: ${{ runner.temp }}/llvm
- name: Set LIBCLANG_PATH
run: echo "LIBCLANG_PATH=$((gcm clang).source -replace "clang.exe")" >> $env:GITHUB_ENV
if: matrix.os == 'windows-latest'
- uses: actions/checkout@main
- uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
components: rustfmt, clippy
- run: cargo fmt --all --check -- --config=imports_granularity=Crate
- uses: taiki-e/install-action@v2
with:
tool: cargo-hack
- run: cargo hack clippy --workspace --each-feature -- -D warnings
- run: cargo hack test --workspace --each-feature