name: lint

on:
  pull_request:
    paths-ignore:
      - "**.md"
      - "**.svg"
      - ".gitignore"
      - "LICENSE"
      - "flake.lock"

jobs:
  treefmt:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v5
      - name: Install Nix
        uses: cachix/install-nix-action@v31
      - name: Run treefmt check
        run: nix build .#checks.x86_64-linux.treefmt --accept-flake-config
