From 3b36a893f76201e00ae4100a32a8e3bccb067ae1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Milan=20P=C3=A4ssler?= Date: Sat, 10 Oct 2020 21:29:13 +0200 Subject: . --- .gitignore | 1 + modules/grub2/default.nix | 15 +++++++-------- 2 files changed, 8 insertions(+), 8 deletions(-) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..b2be92b7db01 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +result diff --git a/modules/grub2/default.nix b/modules/grub2/default.nix index e07b2987bb0c..91aa378753b3 100644 --- a/modules/grub2/default.nix +++ b/modules/grub2/default.nix @@ -10,6 +10,7 @@ in { font = mkOption { type = types.path; + #default = "${pkgs.dejavu_fonts}/share/fonts/truetype/DejaVuSansMono.ttf"; default = "${pkgs.unifont}/share/fonts/truetype/unifont.ttf"; }; }; @@ -20,15 +21,13 @@ in { type = "payload"; src = "${pkgs.coreboot-payload-grub2}/default_payload.elf"; }; - "etc/grub.cfg".src = ./files/grub.cfg; - "etc/background.png".src = ./files/background.png; - "font.pf2" = { - src = pkgs.runCommand "font.pf2" { + "font.pf2".src = ( + pkgs.runCommand "font.pf2" { buildInputs = with pkgs; [ grub2 ]; - } '' - grub-mkfont -o $out ${cfg.font} - ''; - }; + } "grub-mkfont --range=0x20-0x7E,0x2501-0x251F,0x2191-0x2193 --size=14 -o $out ${cfg.font}" + ); + "etc/grub.cfg".src = ./files/grub.cfg; + "background.png".src = ./files/background.png; }; }; } -- cgit v1.2.3