From 5749c1d7df98d8e6aa2bbf9806b6a4d7a08101e0 Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Mon, 2 Oct 2017 16:19:15 +0200 Subject: make sure no other update is pending --- bin/pacman-offline | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/bin/pacman-offline b/bin/pacman-offline index 0b21b09..8f86868 100755 --- a/bin/pacman-offline +++ b/bin/pacman-offline @@ -21,6 +21,12 @@ while getopts 'hy' opt; do esac done +# make sure no other update is pending +if [ "$(readlink '/system-update')" != '/var/cache/pacman/pkg' ]; then + echo 'Another update is pending.' >&2 + exit 1 +fi + # remove the symlink for now, will be recreated it later rm -f /system-update -- cgit v1.2.3-54-g00ecf