Skip to content

ci: add cache to flake #14

ci: add cache to flake

ci: add cache to flake #14

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
package:
- default
name: Build (${{ matrix.os }})
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v11
- name: Setup cache
uses: DeterminateSystems/magic-nix-cache-action@v6
- name: Setup cachix
uses: cachix/cachix-action@v14
with:
name: vdbe
signingKey: "${{ secrets.CACHIX_SIGNING_KEY }}"
authToken: "${{ secrets.CACHIX_TOKEN }}"
- name: Run build
run: |
nix build --print-build-logs .#${{ matrix.package }}
check:
name: Check flake
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v11
- name: Setup cache
uses: DeterminateSystems/magic-nix-cache-action@v6
- name: Setup cachix
uses: cachix/cachix-action@v14
with:
name: vdbe
- name: Run check
run: |
nix flake check --print-build-logs --show-trace