grub: add grub.useOSProber option (#22558)

This commit is contained in:
symphorien
2017-02-13 14:53:15 +01:00
committed by Robin Gloster
parent 5d00edcf4f
commit 0b87efacb1
2 changed files with 20 additions and 3 deletions

View File

@@ -53,12 +53,14 @@ let
inherit (args) devices;
inherit (efi) canTouchEfiVariables;
inherit (cfg)
version extraConfig extraPerEntryConfig extraEntries forceInstall
version extraConfig extraPerEntryConfig extraEntries forceInstall useOSProber
extraEntriesBeforeNixOS extraPrepareConfig configurationLimit copyKernels
default fsIdentifier efiSupport efiInstallAsRemovable gfxmodeEfi gfxmodeBios;
path = (makeBinPath ([
pkgs.coreutils pkgs.gnused pkgs.gnugrep pkgs.findutils pkgs.diffutils pkgs.btrfs-progs
pkgs.utillinux ] ++ (if cfg.efiSupport && (cfg.version == 2) then [pkgs.efibootmgr ] else [])
pkgs.utillinux ]
++ (optional (cfg.efiSupport && (cfg.version == 2)) pkgs.efibootmgr)
++ (optionals cfg.useOSProber [pkgs.busybox pkgs.os-prober])
)) + ":" + (makeSearchPathOutput "bin" "sbin" [
pkgs.mdadm pkgs.utillinux
]);
@@ -265,6 +267,14 @@ in
'';
};
useOSProber = mkOption {
default = false;
type = types.bool;
description = ''
If set to true, append entries for other OSs detected by os-prober.
'';
};
splashImage = mkOption {
type = types.nullOr types.path;
example = literalExample "./my-background.png";