summaryrefslogtreecommitdiff
path: root/flake.nix
blob: 29c76fe745b4c3e87117de1c1422e6e31c0755ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
{
  description = "My CV";
  inputs = {
    nixpkgs.url = "github:nixos/nixpkgs";
    flake-utils.url = "github:numtide/flake-utils";
    nix-filter.url = "github:numtide/nix-filter";
  };

  outputs = { self, nixpkgs, flake-utils, nix-filter, ... }: {
    overlays.default = import ./nix/overlay.nix { inherit nix-filter; };
  } // flake-utils.lib.eachDefaultSystem (system: let
      pkgs = import nixpkgs {
        inherit system;
        overlays = [ self.overlays.default ];
      };
    in {
      packages = {
        inherit (pkgs.haskellPackages) mycv;
        default = pkgs.haskellPackages.mycv;
      };

      devShells.default = pkgs.haskellPackages.shellFor {
        packages = p: [ p.mycv ];
        withHoogle = true;
        buildInputs = with pkgs.haskellPackages; [
          cabal-install
          hpack
        ];
      };
    };
}