Add nix optimise automatically

This commit is contained in:
albert 2024-02-21 11:00:07 +09:00
parent afd3a76470
commit 7c309df1ad
No known key found for this signature in database
GPG key ID: 64F6C4EB46C4543A

View file

@ -2,10 +2,15 @@
# Enable flakes: https://nixos.wiki/wiki/Flakes # Enable flakes: https://nixos.wiki/wiki/Flakes
nix.settings.experimental-features = [ "nix-command" "flakes" ]; nix.settings.experimental-features = [ "nix-command" "flakes" ];
nix.optimise = {
automatic = true;
dates = "daily";
};
# Garbage collection -- Keep the system clean # Garbage collection -- Keep the system clean
nix.gc = { nix.gc = {
automatic = true; automatic = true;
dates = "daily"; dates = "daily";
options = "--delete-older-than 7d"; options = "--delete-older-than 7d";
}; };
} }