2 description = "Alternative Haskell Infrastructure for Nixpkgs";
5 nixpkgs.follows = "nixpkgs-unstable";
6 nixpkgs-2003 = { url = "github:NixOS/nixpkgs/nixpkgs-20.03-darwin"; };
7 nixpkgs-2105 = { url = "github:NixOS/nixpkgs/nixpkgs-21.05-darwin"; };
8 nixpkgs-2111 = { url = "github:NixOS/nixpkgs/nixpkgs-21.11-darwin"; };
9 nixpkgs-unstable = { url = "github:NixOS/nixpkgs/nixpkgs-unstable"; };
10 flake-utils = { url = "github:numtide/flake-utils"; };
13 url = "github:input-output-hk/hackage.nix";
17 url = "github:input-output-hk/stackage.nix";
21 url = "github:haskell/cabal/3.2";
25 url = "github:haskell/cabal/3.4";
29 url = "github:haskell/cabal/3.6";
33 url = "github:input-output-hk/cardano-shell";
38 owner = "input-output-hk";
40 ref = "release/8.6.5-iohk";
44 url = "github:sevanspowell/hpc-coveralls";
48 url = "github:input-output-hk/nix-tools";
52 url = "github:angerman/old-ghc-nix/master";
56 url = "github:phadej/HTTP";
61 outputs = { self, nixpkgs, nixpkgs-unstable, nixpkgs-2105, flake-utils, ... }@inputs:
62 let compiler = "ghc884";
63 config = import ./config.nix;
66 overlay = self.overlays.combined;
67 overlays = import ./overlays { sources = inputs; };
71 overlays = [ self.overlay ];
76 overlaysOverrideable = import ./overlays;
77 # Compatibility with old default.nix
78 compat = { checkMaterialization ?
79 false # Allows us to easily switch on materialization checking
80 , system, sourcesOverride ? { }, ... }@args: rec {
81 sources = inputs // sourcesOverride;
82 allOverlays = import ./overlays (args // { inherit sources; });
84 # We are overriding 'overlays' and 'nixpkgsArgs' from the
85 # flake outputs so that we can incorporate the args passed
86 # to the compat layer (e.g. sourcesOverride).
87 overlays = [ allOverlays.combined ]
88 ++ (if checkMaterialization == true then
91 haskell-nix = prev.haskell-nix // {
92 checkMaterialization = true;
99 inherit config overlays;
101 pkgs = import nixpkgs
102 (nixpkgsArgs // { localSystem = { inherit system; }; });
103 pkgs-unstable = import nixpkgs-unstable
104 (nixpkgsArgs // { localSystem = { inherit system; }; });
105 hix = import ./hix/default.nix { inherit pkgs; };
109 # Note: `nix flake check` evaluates outputs for all platforms, and haskell.nix
110 # uses IFD heavily, you have to have the ability to build for all platforms
111 # supported by haskell.nix, e.g. with remote builders, in order to check this flake.
112 # If you want to run the tests for just your platform, run `./test/tests.sh` or
113 # `nix-build -A checks.$PLATFORM`
114 } // flake-utils.lib.eachSystem [ "x86_64-linux" "x86_64-darwin" "aarch64-linux" "aarch64-darwin" ] (system: {
115 legacyPackages = (self.internal.compat { inherit system; }).pkgs;
116 legacyPackagesUnstable = (self.internal.compat { inherit system; }).pkgs-unstable;
118 # FIXME: Currently `nix flake check` requires `--impure` because coverage-golden
119 # (and maybe other tests) import projects that use builtins.currentSystem
120 checks = builtins.listToAttrs (map (pkg: {
123 }) (nixpkgs.lib.collect nixpkgs.lib.isDerivation (import ./test rec {
124 haskellNix = self.internal.compat { inherit system; };
125 compiler-nix-name = compiler;
126 pkgs = haskellNix.pkgs;
129 devShell = with self.legacyPackages.${system};
134 haskell-nix.compiler.${compiler}
135 haskell-nix.nix-tools.${compiler}
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list