Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Reinstall grub after a package update, and update the /boot/grub/grub.cfg file
- # This hook is intended to prevent one's system of becoming unbootable after a package upgrade
- # Depending on how you installed grub, what shell you use and what is your ESP, adjust this file accordingly!
- # Also, a pacman update will probably overwrite any customizations done to the /etc/default/grub file and files inside /etc/grub.d/
- # In this case, reimplement your customizations and re-run the grub-mkconfig command
- [Trigger]
- Operation = Install
- Operation = Upgrade
- Type = Package
- Target = grub
- [Action]
- Description = Reinstalling and configuring grub...
- When = PostTransaction
- Depends = grub
- Depends = bash
- Exec = /usr/bin/bash -c 'echo; /usr/bin/grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=GRUB; echo; /usr/bin/grub-mkconfig -o /boot/grub/grub.cfg; echo'
- # Suggestion to run more than one command in a single hook found here: https://bbs.archlinux.org/viewtopic.php?pid=1797121#p1797121
- # https://wiki.archlinux.org/title/GRUB#Installation
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement