summaryrefslogtreecommitdiff
path: root/system/bootloader
diff options
context:
space:
mode:
Diffstat (limited to 'system/bootloader')
-rw-r--r--system/bootloader/default.nix6
-rw-r--r--system/bootloader/grub.nix20
-rw-r--r--system/bootloader/limine.nix24
3 files changed, 50 insertions, 0 deletions
diff --git a/system/bootloader/default.nix b/system/bootloader/default.nix
new file mode 100644
index 0000000..8ff8125
--- /dev/null
+++ b/system/bootloader/default.nix
@@ -0,0 +1,6 @@
+_: {
+ imports = [
+ ./grub.nix
+ ./limine.nix
+ ];
+}
diff --git a/system/bootloader/grub.nix b/system/bootloader/grub.nix
new file mode 100644
index 0000000..7f1b31a
--- /dev/null
+++ b/system/bootloader/grub.nix
@@ -0,0 +1,20 @@
+{
+ lib,
+ config,
+ ...
+}: let
+ inherit (lib) mkIf;
+ cfg = config.bootloader.grub;
+in {
+ config = mkIf cfg.enable {
+ boot.loader = {
+ efi.canTouchEfiVariables = true;
+ grub = {
+ enable = true;
+ efiSupport = true;
+ device = "nodev";
+ splashImage = config.theme.wallpaper;
+ };
+ };
+ };
+}
diff --git a/system/bootloader/limine.nix b/system/bootloader/limine.nix
new file mode 100644
index 0000000..3487809
--- /dev/null
+++ b/system/bootloader/limine.nix
@@ -0,0 +1,24 @@
+{
+ lib,
+ config,
+ ...
+}: let
+ inherit (lib) mkIf;
+ cfg = config.bootloader.limine;
+in {
+ config = mkIf cfg.enable {
+ boot.loader = {
+ efi.canTouchEfiVariables = true;
+ limine = {
+ enable = true;
+ efiSupport = true;
+ secureBoot.enable = cfg.secureBoot.enable;
+ maxGenerations = 10;
+ style = {
+ backdrop = config.theme.colors.base;
+ wallpapers = [config.theme.wallpaper];
+ };
+ };
+ };
+ };
+}