From cf5ca2b4d00cf25627b02046f58c186dca8affbd Mon Sep 17 00:00:00 2001 From: Daniel Hansson Date: Mon, 1 Jun 2020 19:55:37 +0200 Subject: [PATCH] only grep the first occurance (not efi) --- nextcloud_update.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nextcloud_update.sh b/nextcloud_update.sh index 5277211d..93a2996f 100644 --- a/nextcloud_update.sh +++ b/nextcloud_update.sh @@ -31,7 +31,7 @@ is_process_running dpkg # Check if /boot is filled more than 90% and exit the script if that's the case since we don't want to end up with a broken system if [ -d /boot ] then - if [[ "$(df -h | grep /boot | awk '{print $5}' | cut -d "%" -f1)" -gt 90 ]] + if [[ "$(df -h | grep -m 1 /boot | awk '{print $5}' | cut -d "%" -f1)" -gt 90 ]] then msg_box "It seems like your boot drive is filled more than 90%. You can't proceed to upgrade since it probably will break your system