A flake checker (treefmt & nix-unit) for testing other flakes with zero dependencies.
README.md

Sponsor Vic Dendritic Nix License CI Status

Checkmate - A Dendritic flake checker (treefmt & nix-unit) for testing other flakes with zero dependencies. #

checkmate and vic's dendritic libs made for you with Love++ and AI--. If you like my work, consider sponsoring

Checks included by default #

  • treefmt - nixfmt, deadnix, mdformat, yamlfmt. See treefmt.nix.

  • nix-unit - The flake being checked is available as inputs.target

Extensible. #

Checkmate is a collection of Dendritic modules.

Getting started #

# Generate a new project including github CI action
nix flake new -t github:vic/checkmate

Running flake check locally #

nix flake check github:vic/checkmate --override-input target .

Running treefmt on your code #

# formatting your code
nix run github:vic/checkmate#fmt --override-input target .

# checking if code is formatted
nix run github:vic/checkmate#fmt --override-input target . -- --ci

CI Usage #

On your github action:

on:
  pull_request:
  push:
jobs:
  checkmate:
    name: checkmate
    runs-on: ubuntu-latest
    steps:
      - uses: cachix/install-nix-action@v30
      - run: nix flake check -L github:vic/checkmate --override-input target github:$GITHUB_REPOSITORY/$GITHUB_SHA

Examples #

Some repos being tested with checkmate: