Skip to content

Commit 1f81f80

Browse files
authored
Revert "Drop flake stuff, I don't understand it" (#46)
This reverts commit 0c3b23b.
1 parent fdb3b5a commit 1f81f80

File tree

2 files changed

+90
-0
lines changed

2 files changed

+90
-0
lines changed

flake.lock

Lines changed: 61 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
{
2+
inputs = {
3+
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
4+
flake-utils.url = "github:numtide/flake-utils";
5+
};
6+
7+
outputs = { self, nixpkgs, flake-utils }:
8+
flake-utils.lib.eachDefaultSystem (system:
9+
let
10+
pkgs = nixpkgs.legacyPackages.${system};
11+
overlay = final: prev: {
12+
hell = prev.callCabal2nix "hell" ./. { };
13+
};
14+
haskellPackages = pkgs.haskellPackages.extend overlay;
15+
in {
16+
# nix build
17+
packages.default = haskellPackages.hell;
18+
19+
# nix develop
20+
devShells.default = haskellPackages.shellFor {
21+
packages = p: [ p.hell ];
22+
buildInputs = with haskellPackages; [
23+
cabal-install
24+
haskell-language-server
25+
];
26+
};
27+
}
28+
);
29+
}

0 commit comments

Comments
 (0)