mirror of
https://github.com/ilyakooo0/haskell.nix.git
synced 2024-09-11 06:55:40 +03:00
Fix non-flake compatibility layer. (#1204)
Previously 'overlays' was being taken from the non-compat flake output and nixpkgsArgs referenced the wrong version. Fixes #1192
This commit is contained in:
parent
c87907aca6
commit
1729233076
@ -13,5 +13,5 @@ let
|
||||
sha256 = "sha256:054nsfqh3wy6v6bjamw0k91xl8v1rc5x2laic8mphrkrhzvyz5hi";
|
||||
};
|
||||
self = import flake-compat { src = ./.; inherit pkgs; };
|
||||
in self.defaultNix.internal.compat
|
||||
({ system = args.pkgs.system or builtins.currentSystem; } // args) // self.defaultNix
|
||||
in self.defaultNix // (self.defaultNix.internal.compat
|
||||
({ system = args.pkgs.system or builtins.currentSystem; } // args))
|
||||
|
10
flake.nix
10
flake.nix
@ -73,8 +73,11 @@
|
||||
false # Allows us to easily switch on materialization checking
|
||||
, system, sourcesOverride ? { }, ... }@args: rec {
|
||||
sources = inputs // sourcesOverride;
|
||||
allOverlays = import ./overlays args;
|
||||
inherit config nixpkgsArgs;
|
||||
allOverlays = import ./overlays (args // { inherit sources; });
|
||||
inherit config;
|
||||
# We are overriding 'overlays' and 'nixpkgsArgs' from the
|
||||
# flake outputs so that we can incorporate the args passed
|
||||
# to the compat layer (e.g. sourcesOverride).
|
||||
overlays = [ allOverlays.combined ]
|
||||
++ (if checkMaterialization == true then
|
||||
[
|
||||
@ -86,6 +89,9 @@
|
||||
]
|
||||
else
|
||||
[ ]);
|
||||
nixpkgsArgs = {
|
||||
inherit config overlays;
|
||||
};
|
||||
pkgs = import nixpkgs
|
||||
(nixpkgsArgs // { localSystem = { inherit system; }; });
|
||||
pkgs-unstable = import nixpkgs-unstable
|
||||
|
Loading…
Reference in New Issue
Block a user