blob: 33d3ff6053c2a5f55bd2bcb00420b2840aa9f9a6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
regenerate_grub_config() {
if command -v grub-mkconfig > /dev/null 2>&1; then
echo "Regenerating GRUB configuration..."
grub-mkconfig -o /boot/grub/grub.cfg
fi
}
regenerate_initramfs() {
if command -v mkinitcpio > /dev/null 2>&1; then
echo "Regenerating initramfs..."
mkinitcpio --allpresets
fi
}
post_install() {
regenerate_grub_config
regenerate_initramfs
}
post_remove() {
regenerate_grub_config
regenerate_initramfs
}
post_upgrade() {
regenerate_initramfs
}
|