modules/nixos: use latest nixos-option to support flakes
This commit is contained in:
parent
250931a8fd
commit
71f3379ae2
2 changed files with 5 additions and 2 deletions
modules
|
@ -1,4 +1,4 @@
|
|||
{ lib, pkgs, ... }:
|
||||
{ lib, ... }:
|
||||
|
||||
{
|
||||
imports = [ ./common.nix ];
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ lib, inputs, config, ... }:
|
||||
{ lib, inputs, config, pkgs, ... }:
|
||||
|
||||
let
|
||||
inherit (builtins) elem;
|
||||
|
@ -24,6 +24,9 @@ in
|
|||
};
|
||||
|
||||
config = {
|
||||
environment.systemPackages =
|
||||
lib.optional config.system.tools.nixos-option.enable pkgs.unstable.nixos-option;
|
||||
|
||||
nixpkgs.config.allowUnfreePredicate = lib.mkIf
|
||||
(cfg.allowUnfreePackages != [ ])
|
||||
(pkg: elem (lib.getName pkg) cfg.allowUnfreePackages);
|
||||
|
|
Loading…
Add table
Reference in a new issue