name: CI
on:
push:
branches: [main, develop]
pull_request:
branches: [main, develop]
env:
CARGO_TERM_COLOR: always
permissions:
contents: read
jobs:
check:
name: Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Install devenv
run: nix profile install nixpkgs#devenv
- name: Check workspace
run: devenv shell -- ./bin/check
test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Install devenv
run: nix profile install nixpkgs#devenv
- name: Test workspace
run: devenv shell -- ./bin/test
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Install devenv
run: nix profile install nixpkgs#devenv
- name: Lint workspace
run: devenv shell -- ./bin/lint
format:
name: Format
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Install devenv
run: nix profile install nixpkgs#devenv
- name: Format workspace
run: devenv shell -- ./bin/format
docs:
name: Docs
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Install devenv
run: nix profile install nixpkgs#devenv
- name: Build docs
run: devenv shell -- ./bin/docs
- name: Check docs (missing docs)
run: devenv shell -- ./bin/check-docs
continue-on-error: true