name: CI on: push: pull_request: env: CARGO_TERM_COLOR: always jobs: test-matrix: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-22.04, windows-latest, macos-latest] steps: - uses: actions/checkout@v4 - name: Install Rust run: | rustup default 1.69.0 rustup component add clippy - name: Test run: | cargo test - name: Clippy run: | cargo clippy --all-targets --all-features -- -D warnings - name: Build and run examples run: | cargo build --examples cargo run --example print_libc musl-build: runs-on: ubuntu-22.04 needs: test-matrix steps: - uses: actions/checkout@v4 - name: Install Rust and musl target run: | rustup default 1.69.0 rustup target add x86_64-unknown-linux-musl - name: Install musl toolchain run: | sudo apt-get update sudo apt-get install -y musl-tools - name: Build tests for musl run: | cargo test --target x86_64-unknown-linux-musl