flake/.github/workflows/nix.yml

37 lines
985 B
YAML

name: Nix
on:
push:
paths-ignore:
- README.md
pull_request:
paths-ignore:
- README.md
jobs:
build:
strategy:
matrix:
target-system:
- ymir
- tartarus
- pochita
- pochita-sd
- harmonica
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v31
# TODO: add a binary cache
# - uses: cachix/cachix-action@v10
# with:
# name: YOURCACHE
# authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
- run: nix flake check --accept-flake-config
# Pre-build the system configuration
- run: nix build --accept-flake-config --dry-run .#nixosConfigurations.${{ matrix.target-system }}.config.system.build.toplevel
check-formatting:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v31
- run: nix run nixpkgs#nixfmt-tree -- --ci