-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
64 lines (58 loc) · 1.55 KB
/
flake.nix
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
{
description = "Simple pool implementation";
inputs = {
flake-utils.url = github:numtide/flake-utils;
};
outputs = { self, nixpkgs, flake-utils }: {
overlay = final: prev: {
haskell = prev.haskell // {
packageOverrides =
final.lib.composeExtensions
(prev.haskell.packageOverrides or (_: _: { }))
(hfinal: hprev: {
simpoole =
hfinal.callCabal2nix "simpoole"
(
final.nix-gitignore.gitignoreSourcePure
[
./.gitignore
"*.nix"
"flake.lock"
"*.yaml"
"cabal.project*"
".vscode"
".github"
"*.md"
]
self
)
{ };
});
};
};
} // flake-utils.lib.eachDefaultSystem (system:
with (import nixpkgs {
inherit system;
overlays = [ self.overlay ];
});
{
packages = {
simpoole = haskellPackages.simpoole;
};
defaultPackage = self.packages.${system}.simpoole;
checks = {
simpoole = self.packages.${system}.simpoole.overrideAttrs (_: { doCheck = true; });
};
devShell = mkShell {
buildInputs = [
ghc
cabal-install
haskell-language-server
hlint
stylish-haskell
nixpkgs-fmt
];
};
}
);
}