From d8508799174b4d4977f5fec4648ff1650d1fdef8 Mon Sep 17 00:00:00 2001 From: moons14 Date: Thu, 30 Oct 2025 07:37:54 +0900 Subject: [PATCH] gc --- modules/core/boot.nix | 1 + modules/core/default.nix | 1 + modules/core/gc.nix | 11 +++++++++++ 3 files changed, 13 insertions(+) create mode 100644 modules/core/gc.nix diff --git a/modules/core/boot.nix b/modules/core/boot.nix index a96a850..e13790c 100644 --- a/modules/core/boot.nix +++ b/modules/core/boot.nix @@ -2,6 +2,7 @@ { boot.loader = { systemd-boot.enable = true; + systemd-boot.configurationLimit = 8; efi.canTouchEfiVariables = true; }; } \ No newline at end of file diff --git a/modules/core/default.nix b/modules/core/default.nix index 9c9b6e8..3ce97ea 100644 --- a/modules/core/default.nix +++ b/modules/core/default.nix @@ -4,6 +4,7 @@ ./boot.nix ./environment.nix ./fonts.nix + ./gc.nix ./hardware.nix ./i18n.nix ./network.nix diff --git a/modules/core/gc.nix b/modules/core/gc.nix new file mode 100644 index 0000000..76bbd7f --- /dev/null +++ b/modules/core/gc.nix @@ -0,0 +1,11 @@ +{ ... }: +{ + nix.gc = { + automatic = true; + dates = "daily"; + options = "--delete-older-than 7d"; + }; + + nix.settings.auto-optimise-store = true; + nix.optimise.automatic = true; +} \ No newline at end of file