43 lines
943 B
YAML
43 lines
943 B
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [master, main]
|
|
pull_request:
|
|
|
|
jobs:
|
|
check:
|
|
name: Check & Clippy
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Install Rust (stable)
|
|
uses: dtolnay/rust-toolchain@stable
|
|
with:
|
|
components: clippy
|
|
|
|
- name: Cache cargo
|
|
uses: actions/cache@v4
|
|
with:
|
|
path: |
|
|
~/.cargo/registry
|
|
~/.cargo/git
|
|
target
|
|
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.toml') }}
|
|
restore-keys: ${{ runner.os }}-cargo-
|
|
|
|
- name: Install system dependencies
|
|
run: |
|
|
sudo apt-get update -q
|
|
sudo apt-get install -y --no-install-recommends \
|
|
libwayland-dev \
|
|
libxkbcommon-dev \
|
|
pkg-config
|
|
|
|
- name: cargo check
|
|
run: cargo check
|
|
|
|
- name: cargo clippy
|
|
run: cargo clippy -- -D warnings
|