{
  description = "A Haskell Sudoku solver using CSV input";
  inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.11";
  inputs.flake-utils.url = "github:numtide/flake-utils";

  outputs =
    {
      self,
      nixpkgs,
      flake-utils,
    }:
    flake-utils.lib.eachDefaultSystem (
      system:
      let
        pkgs = import nixpkgs { inherit system; };
        hsPkgs = pkgs.haskellPackages;
      in
      {
        packages.default = hsPkgs.callCabal2nix "sudoku-solver" ./. { };
        apps.default = {
          type = "app";
          program = "${self.packages.${system}.default}/bin/sudoku-solver";
        };
      }
    );
}
