add upgrade grub on efi

This commit is contained in:
dz00te 2021-05-06 19:30:49 +02:00
parent 246a685a64
commit 2eba3ded44

View File

@ -137,6 +137,14 @@ sig_swaps() {
exit_message "Not Available" exit_message "Not Available"
} }
grub_swap() {
if [ -d /sys/firmware/efi ]; then
grub2-mkconfig -o /boot/efi/EFI/rocky/grub.cfg
else
grub2-mkconfig -o /boot/grub2/grub.cfg
fi
}
module_check() { module_check() {
echo -e "$blue""Finding our modules that are enabled""$nocolor" echo -e "$blue""Finding our modules that are enabled""$nocolor"
for module in "${enabled_modules[@]}"; do for module in "${enabled_modules[@]}"; do
@ -252,6 +260,9 @@ module_check
# Actually do the swap and distro-sync # Actually do the swap and distro-sync
package_swaps package_swaps
# Reconfigure grub
grub_swap
# Fix up modules # Fix up modules
module_fix module_fix