feat: add a fmt github action

This commit is contained in:
Nickolaj Jepsen 2025-12-13 19:41:40 +01:00
parent 76055bdf3f
commit 2c0c99180e
4 changed files with 50 additions and 9 deletions

32
.github/workflows/fmt.yml vendored Normal file
View file

@ -0,0 +1,32 @@
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
fmt:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Check formatting
run: nix fmt -- --fail-on-change
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Run nix flake check
run: nix flake check