diff options
author | Christian Hesse <mail@eworm.de> | 2023-07-10 10:45:41 +0200 |
---|---|---|
committer | Christian Hesse <mail@eworm.de> | 2023-07-10 22:03:48 +0200 |
commit | 6147875514edec881f07a79fd75e161e8d2efe60 (patch) | |
tree | c94cccdf833f031fea176c438f90e5fc772826db /systemd/pacman-offline | |
parent | 84a906395b3672f8ad6ac49d5b3f04f9f90bac66 (diff) | |
download | pacman-offline-6147875514edec881f07a79fd75e161e8d2efe60.tar.gz pacman-offline-6147875514edec881f07a79fd75e161e8d2efe60.tar.zst |
do a soft-reboot in second step...
... if the modules for running kernel are still available.
Diffstat (limited to 'systemd/pacman-offline')
-rwxr-xr-x | systemd/pacman-offline | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/systemd/pacman-offline b/systemd/pacman-offline index 39ed094..48692eb 100755 --- a/systemd/pacman-offline +++ b/systemd/pacman-offline @@ -25,4 +25,8 @@ pacman --config /run/pacman.conf --sync --noconfirm --sysupgrade pacman --sync --noconfirm --clean # reboot -systemctl reboot +if [ -s "/usr/lib/modules/$(uname -r)/pkgbase" ]; then + systemctl soft-reboot +else + systemctl reboot +fi |