Skip to content

feat: better error handling #59

feat: better error handling

feat: better error handling #59

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
env:
CARGO_TERM_COLOR: always
NIX_DEV: nix develop --command
CARGO_FLAGS: --all-targets --all-features
jobs:
rustfmt:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v14
- name: Cache Nix store
uses: DeterminateSystems/magic-nix-cache-action@v8
- name: Run rustfmt
run: $NIX_DEV cargo fmt --all -- --check
clippy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v14
- name: Cache Nix store
uses: DeterminateSystems/magic-nix-cache-action@v8
- name: Run clippy
run: $NIX_DEV cargo clippy --workspace $CARGO_FLAGS -- -D warnings
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v14
- name: Cache Nix store
uses: DeterminateSystems/magic-nix-cache-action@v8
- name: Build
run: $NIX_DEV cargo build $CARGO_FLAGS
- name: Run tests
run: $NIX_DEV cargo test $CARGO_FLAGS