Skip to content

Commit 1020c59

Browse files
committed
autoformat nix file
1 parent 179e610 commit 1020c59

File tree

1 file changed

+24
-32
lines changed

1 file changed

+24
-32
lines changed

nix/default.nix

Lines changed: 24 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -3,47 +3,39 @@
33
let
44
inherit (pkgs.lib) fold composeExtensions concatMap attrValues;
55

6-
combineOverrides = old:
7-
fold composeExtensions (old.overrides or (_: _: { }));
6+
combineOverrides = old: fold composeExtensions (old.overrides or (_: _: { }));
87

9-
makeTestConfiguration = { ghc ? pkgs.haskellPackages, overrides ? new: old: { } }:
10-
let
11-
inherit (pkgs.haskell.lib) dontCheck packageSourceOverrides;
12-
in
13-
(ghc.override (old: {
14-
overrides =
15-
combineOverrides old [
16-
(packageSourceOverrides { monads-tf = ../monads-tf; })
17-
overrides
18-
];
19-
})).monads-tf;
20-
testConfigurations =
21-
rec {
22-
ghc-9-2 = makeTestConfiguration {
23-
ghc = pkgs.haskell.packages.ghc92;
24-
};
25-
ghc-9-4 = makeTestConfiguration {
26-
ghc = pkgs.haskell.packages.ghc94;
27-
};
28-
ghc-9-6 = makeTestConfiguration {
29-
ghc = pkgs.haskell.packages.ghc96;
30-
overrides = new: old: {
8+
makeTestConfiguration =
9+
{ ghc ? pkgs.haskellPackages, overrides ? new: old: { } }:
10+
let inherit (pkgs.haskell.lib) dontCheck packageSourceOverrides;
11+
in (ghc.override (old: {
12+
overrides = combineOverrides old [
13+
(packageSourceOverrides { monads-tf = ../monads-tf; })
14+
overrides
15+
];
16+
})).monads-tf;
17+
testConfigurations = rec {
18+
ghc-9-2 = makeTestConfiguration { ghc = pkgs.haskell.packages.ghc92; };
19+
ghc-9-4 = makeTestConfiguration { ghc = pkgs.haskell.packages.ghc94; };
20+
ghc-9-6 = makeTestConfiguration {
21+
ghc = pkgs.haskell.packages.ghc96;
22+
overrides = new: old:
23+
{
3124
# transformers = new.callHackage "transformers" "0.5.6.2" { };
3225
};
33-
};
34-
all = pkgs.symlinkJoin {
35-
name = "monads-tf-tests";
36-
paths = [ ghc-9-2 ghc-9-4 ghc-9-6 ];
37-
};
3826
};
27+
all = pkgs.symlinkJoin {
28+
name = "monads-tf-tests";
29+
paths = [ ghc-9-2 ghc-9-4 ghc-9-6 ];
30+
};
31+
};
3932

40-
in
41-
{
33+
in {
4234

4335
packages = { inherit testConfigurations; };
4436

4537
devShells.default = pkgs.mkShell {
46-
inputsFrom = [ (makeTestConfiguration {}).env ];
38+
inputsFrom = [ (makeTestConfiguration { }).env ];
4739
buildInputs = [ pkgs.haskell-language-server pkgs.cabal-install ];
4840
};
4941

0 commit comments

Comments
 (0)