Skip to content

windows: Build without uzers #4

windows: Build without uzers

windows: Build without uzers #4

Workflow file for this run

name: Build
on:
push:
branches: [ "**" ]
pull_request:
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
CARGO_TERM_COLOR: always
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install libudev-dev
run: sudo apt-get update && sudo apt-get install -y libudev-dev
- uses: moonrepo/setup-rust@v1
with:
components: rustfmt
- name: Check formatting
run: cargo fmt --all --check
- uses: moonrepo/setup-rust@v1
with:
bins: cargo-make
components: clippy
- name: Run Clippy
run: cargo make lint
- uses: moonrepo/setup-rust@v1
with:
bins: cargo-make
components: clippy
- name: Run tests
run: cargo make test
build:
name: Build
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- build: linux
os: ubuntu-latest
use-cross: false
target: x86_64-unknown-linux-gnu
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install libudev-dev
run: sudo apt-get update && sudo apt-get install -y libudev-dev
- name: Install cross
if: matrix.use-cross
uses: taiki-e/install-action@v2
with:
tool: cross
- uses: moonrepo/setup-rust@v1
with:
targets: ${{ matrix.target }}
- name: Build (without cross)
if: "!matrix.use-cross"
run: cargo build --release --locked --target ${{ matrix.target }}
- name: Build (cross)
if: matrix.use-cross
run: cross build --release --locked --target ${{ matrix.target }}