From 99f1dd3ec8ee6154fb897beb250e7051671241e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1s=20Rivera?= Date: Fri, 12 Jun 2026 15:07:06 +0200 Subject: [PATCH 1/5] bootloader: reunited desktop and laptop config --- modules/hardware/bootloader.nix | 16 +--------------- modules/hosts/desktop.nix | 2 +- modules/hosts/laptop.nix | 2 +- 3 files changed, 3 insertions(+), 17 deletions(-) diff --git a/modules/hardware/bootloader.nix b/modules/hardware/bootloader.nix index cd6ad2a..c6ebf4f 100644 --- a/modules/hardware/bootloader.nix +++ b/modules/hardware/bootloader.nix @@ -1,19 +1,5 @@ _: { - flake.nixosModules.bootloader-laptop = { - inputs, - pkgs, - ... - }: { - # grub theme - boot.loader.grub = { - theme = inputs.nixos-grub-themes.packages.${pkgs.system}.nixos; # if you want to use nixos grub theme - }; - - # Bootloader. - boot.loader.systemd-boot.enable = true; - boot.loader.efi.canTouchEfiVariables = true; - }; - flake.nixosModules.bootloader-desktop = { + flake.nixosModules.bootloader = { inputs, pkgs, ... diff --git a/modules/hosts/desktop.nix b/modules/hosts/desktop.nix index fa83317..24a51d8 100644 --- a/modules/hosts/desktop.nix +++ b/modules/hosts/desktop.nix @@ -20,7 +20,7 @@ autoCleanup-desktop autoUpdate-desktop bluetooth - bootloader-desktop + bootloader browsers caelestia development diff --git a/modules/hosts/laptop.nix b/modules/hosts/laptop.nix index 85fe064..24d548f 100644 --- a/modules/hosts/laptop.nix +++ b/modules/hosts/laptop.nix @@ -20,7 +20,7 @@ autoUpdate-laptop #battery-laptop bluetooth - bootloader-laptop + bootloader browsers caelestia development From 763bbbacd4f74e70174cf7d5221efdf6f478ad62 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1s=20Rivera?= Date: Fri, 12 Jun 2026 15:10:42 +0200 Subject: [PATCH 2/5] bootloader: limine --- flake.nix | 1 - modules/hardware/bootloader.nix | 12 +++++++----- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/flake.nix b/flake.nix index 363ea8a..d340f1d 100644 --- a/flake.nix +++ b/flake.nix @@ -4,7 +4,6 @@ inputs = { nixpkgs.url = "github:nixos/nixpkgs/nixos-26.05"; nixpkgs-unstable.url = "github:nixos/nixpkgs/nixpkgs-unstable"; # used for some packages - nixos-grub-themes.url = "github:jeslie0/nixos-grub-themes"; nixpkgs-master.url = "github:nixos/nixpkgs/master"; # used with precaution as they are untested and not cached # This one is only used when testing some packaging. You must change the path to the correct nixpkgs clone diff --git a/modules/hardware/bootloader.nix b/modules/hardware/bootloader.nix index c6ebf4f..67f72b2 100644 --- a/modules/hardware/bootloader.nix +++ b/modules/hardware/bootloader.nix @@ -4,13 +4,15 @@ _: { pkgs, ... }: { - # grub theme - boot.loader.grub = { - theme = inputs.nixos-grub-themes.packages.${pkgs.system}.nixos; # if you want to use nixos grub theme + # disable other bootloaders + boot.loader.systemd-boot.enable = false; + boot.loader.grub.enable = false; + + boot.loader.limine = { + enable = true; + efiSupport = true; }; - # Bootloader. - boot.loader.systemd-boot.enable = true; boot.loader.efi.canTouchEfiVariables = true; }; } From 2a318bdced01be829663c83277eb1eb67974f486 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1s=20Rivera?= Date: Fri, 12 Jun 2026 15:37:43 +0200 Subject: [PATCH 3/5] hosts: forgot to use nixUtils module --- modules/hardware/bootloader.nix | 2 ++ modules/hosts/desktop.nix | 1 + modules/hosts/laptop.nix | 2 ++ modules/utilities/nixUtils.nix | 2 +- 4 files changed, 6 insertions(+), 1 deletion(-) diff --git a/modules/hardware/bootloader.nix b/modules/hardware/bootloader.nix index 67f72b2..600d893 100644 --- a/modules/hardware/bootloader.nix +++ b/modules/hardware/bootloader.nix @@ -11,6 +11,8 @@ _: { boot.loader.limine = { enable = true; efiSupport = true; + extraConfig = '' + ''; }; boot.loader.efi.canTouchEfiVariables = true; diff --git a/modules/hosts/desktop.nix b/modules/hosts/desktop.nix index 24a51d8..b56cb9d 100644 --- a/modules/hosts/desktop.nix +++ b/modules/hosts/desktop.nix @@ -38,6 +38,7 @@ mathematics mullvad networking + nixUtils notifications nvidia office diff --git a/modules/hosts/laptop.nix b/modules/hosts/laptop.nix index 24d548f..0ff6de1 100644 --- a/modules/hosts/laptop.nix +++ b/modules/hosts/laptop.nix @@ -39,6 +39,8 @@ mathematics mullvad networking + nixUtils-laptop + nixUtils notifications office #ollama diff --git a/modules/utilities/nixUtils.nix b/modules/utilities/nixUtils.nix index a7c4531..93d8f9b 100644 --- a/modules/utilities/nixUtils.nix +++ b/modules/utilities/nixUtils.nix @@ -10,7 +10,7 @@ nix.optimise = { automatic = true; persistent = true; - randomDelaySec = "30min"; + randomizedDelaySec = "30min"; dates = "Thu *-*-* 16:00:00"; }; # Garbage collector of generations From 29554e41cae5a6b02999b7214b8aab2bb235279b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1s=20Rivera?= Date: Fri, 12 Jun 2026 15:46:20 +0200 Subject: [PATCH 4/5] nixUtils: add custom-trimmer --- modules/utilities/nixUtils.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/utilities/nixUtils.nix b/modules/utilities/nixUtils.nix index 93d8f9b..36964b6 100644 --- a/modules/utilities/nixUtils.nix +++ b/modules/utilities/nixUtils.nix @@ -1,4 +1,4 @@ -{inputs, ...}: { +{inputs, self, ...}: { flake.nixosModules.nixUtils-laptop = _: { # nixpkgs-review crashed my laptop multiple times. We must reduce how much ressources it can take. # for reference, my laptop is a 12 core ryzen 7 @@ -40,6 +40,7 @@ vimPluginsUpdater # used for building plugins nix-index statix + self.packages.${pkgs-unstable.system}.custom-trimmer ]; }; perSystem = {pkgs, ...}: { From d49c7ba99e0296aa7b8b283f724e212014c359eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1s=20Rivera?= Date: Fri, 12 Jun 2026 15:58:17 +0200 Subject: [PATCH 5/5] limine: rice --- modules/hardware/bootloader.nix | 27 +++++++++++++++++++-------- 1 file changed, 19 insertions(+), 8 deletions(-) diff --git a/modules/hardware/bootloader.nix b/modules/hardware/bootloader.nix index 600d893..10720b3 100644 --- a/modules/hardware/bootloader.nix +++ b/modules/hardware/bootloader.nix @@ -1,9 +1,11 @@ -_: { - flake.nixosModules.bootloader = { - inputs, - pkgs, - ... - }: { +_: let + wallpaper1 = ../../assets/wallpaper1.jpg; + wallpaper2 = ../../assets/wallpaper2.jpg; + wallpaper3 = ../../assets/wallpaper3.jpg; + wallpaper4 = ../../assets/wallpaper4.jpg; + wallpaper5 = ../../assets/wallpaper5.jpg; +in { + flake.nixosModules.bootloader = _: { # disable other bootloaders boot.loader.systemd-boot.enable = false; boot.loader.grub.enable = false; @@ -11,8 +13,17 @@ _: { boot.loader.limine = { enable = true; efiSupport = true; - extraConfig = '' - ''; + maxGenerations = 128; + style = { + wallpaperStyle = "centered"; + wallpapers = [ + wallpaper1 + wallpaper2 + wallpaper3 + wallpaper4 + wallpaper5 + ]; + }; }; boot.loader.efi.canTouchEfiVariables = true;