blob: 181d770c0c5afe66ecb576ccef573fb075d5d46f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
{ config, lib, ... }:
{
options.nix = {
experimentalFeatures = lib.mkOption {
type = lib.types.separatedString " ";
default = "";
description = ''
Enables experimental features
'';
};
};
config = lib.mkMerge [
(lib.mkIf
(config.nix.experimentalFeatures != "")
{ nix.extraOptions = "experimental-features = ${config.nix.experimentalFeatures}"; })
{
nix.settings.auto-optimise-store = lib.mkDefault true;
nix.gc.automatic = lib.mkDefault true;
nix.gc.options = lib.mkDefault "--delete-older-than 10d";
}
];
}
|