https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
10 lines
312 B
INI
10 lines
312 B
INI
# The parentheses around ${root} here to match Grub's config file syntax
|
|
if search -s -f /boot/grub/grub.cfg ; then
|
|
echo "Reading (${root})/boot/grub/grub.cfg"
|
|
configfile /boot/grub/grub.cfg
|
|
fi
|
|
|
|
if search -s -f /grub/grub.cfg ; then
|
|
echo "Reading (${root})/grub/grub.cfg"
|
|
configfile /grub/grub.cfg
|
|
fi
|