beads/.github/workflows/nix-build.yml
matt wilkie b90ee4cf4c
ci: add nix build check to catch vendorHash drift (GH#3298) (#3364)
Adds a CI job that runs `nix build .#default` on PRs touching go.mod,
go.sum, default.nix, flake.nix, or flake.lock, so dependabot bumps
that invalidate vendorHash fail loudly in CI instead of silently
breaking Nix users on main (as happened in GH#3221).

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-20 13:21:53 -07:00

31 lines
616 B
YAML

name: nix build
on:
pull_request:
paths:
- 'go.mod'
- 'go.sum'
- 'default.nix'
- 'flake.nix'
- 'flake.lock'
push:
branches: [main]
paths:
- 'go.mod'
- 'go.sum'
- 'default.nix'
- 'flake.nix'
- 'flake.lock'
workflow_dispatch:
jobs:
nix-build:
name: nix build .#default
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v6
- name: Install Nix
uses: DeterminateSystems/determinate-nix-action@v3
- name: Build
run: nix build .#default --print-build-logs