nixos-config/modules/flakes.nix

18 lines
354 B
Nix
Raw Normal View History

2021-01-17 22:08:34 +00:00
{ config, pkgs, lib, ... }:
let
cfg = config.sconfig.flakes;
in
{
options.sconfig.flakes = lib.mkEnableOption "Enable Flakes";
config = lib.mkIf cfg {
environment.systemPackages = [ pkgs.nixFlakes ];
nix = {
package = pkgs.nixFlakes;
extraOptions = ''
experimental-features = nix-command flakes
'';
};
};
}