Skip to content

Use Rust cache for GitHub actions #96

Use Rust cache for GitHub actions

Use Rust cache for GitHub actions #96

Workflow file for this run

name: CI
on:
pull_request:
types: [ opened, synchronize ]
push:
jobs:
do-various-checks:
runs-on: [ubuntu-latest]
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Restore Rust cache
uses: Swatinem/rust-cache@v2
- name: Format Rust code
env:
TERM: xterm-256color # Make output colored. Only works on step, not on job.
run: cargo fmt --all --check -- --color always
- name: Clippy
env:
TERM: xterm-256color
run: cargo clippy --all-targets --all-features --color always -- -D warnings
- name: Unit tests
run: cargo test --color always