diff options
-rwxr-xr-x | bin/pacman-offline | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/bin/pacman-offline b/bin/pacman-offline index 346e843..3d218f9 100755 --- a/bin/pacman-offline +++ b/bin/pacman-offline @@ -46,6 +46,11 @@ if systemd-detect-virt --chroot; then exit 0 fi +if [ ! -d /run/systemd/system ]; then + echo 'Current root is not booted, skipping.' >&2 + exit 0 +fi + if [ "${UID}" -ne 0 ]; then if command -v pkexec >/dev/null; then echo 'Missing privileges, trying to elevate.' >&2 |