commit 0364b43b5ec2cc4eb2cadd618b5f3e08b3b4285f
parent 5939b68616da5c80ad11ecb6c3ad65766757559b
Author: Vincent Demeester <vincent@sbr.pm>
Date: Mon, 25 May 2020 09:13:50 +0200
default.nix: fix cfg.type detection
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Diffstat:
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/default.nix b/default.nix
@@ -1,7 +1,7 @@
{ sources ? import ./nix
, lib ? sources.lib
, pkgs ? sources.pkgs { }
-, pkgs-unstable ? sources.pkgs-unstable
+, pkgs-unstable ? sources.pkgs-unstable { }
, nixpkgs ? sources.nixpkgs { }
}:
with builtins; with lib;
@@ -23,7 +23,7 @@ let
system = cfg.arch;
# If type == unstable, use nixos-unstable (pkgs-unstable) otherwise use nixos (pkgs)
p =
- if cfg.type == "unstable"
+ if cfg ? type && cfg.type == "unstable"
then pkgs-unstable
else pkgs;
nixos = import (p.path + "/nixos") { inherit configuration system; };