Add support for dracut and booster for the hook (#163)

This commit is contained in:
Vasiliy Stelmachenok 2023-05-04 21:58:17 +03:00 committed by GitHub
parent c758da09ff
commit f4914fd9e5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -14,4 +14,4 @@ Target=nvidia-open-dkms-tkg
Description=Update Nvidia modules in initcpio Description=Update Nvidia modules in initcpio
When=PostTransaction When=PostTransaction
NeedsTargets NeedsTargets
Exec=/bin/sh -c 'if command -v mkinitcpio >/dev/null 2>&1; then mkinitcpio -P; else printf "\\033[31m mkinitcpio not found, please update initramfs manually\\033[0m\\n"; fi' Exec=/bin/sh -c 'if command -v mkinitcpio >/dev/null 2>&1; then mkinitcpio -P; elif command -v /usr/lib/booster/regenerate_images >/dev/null 2>&1; then /usr/lib/booster/regenerate_images; elif command -v dracut >/dev/null 2>&1; then dracut --regenerate-all --force; else printf "\\033[31m The initramfs generator was not found, please update initramfs manually\\033[0m\\n"; fi'