From 32f8ce1c5566f99f25804207d7eed97cc15795b3 Mon Sep 17 00:00:00 2001 From: velvettear Date: Tue, 5 Nov 2024 16:27:47 +0100 Subject: [PATCH] fix alpine update script --- scripts/update/alpine.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/update/alpine.sh b/scripts/update/alpine.sh index 02ff4a4..56dfb0d 100755 --- a/scripts/update/alpine.sh +++ b/scripts/update/alpine.sh @@ -29,10 +29,6 @@ printf ""$font_colored_bold">> system update started..."$font_default"\n" printf ""$font_colored"> updating packages..."$font_default"\n" [[ "$noconfirm" ]] && apk --update-cache upgrade --progress || apk --update-cache upgrade --progress --interactive -#printf ""$font_colored"> cleaning cache..."$font_default"\n" -#apk cache clean &> /dev/null -#rm -rf "/var/cache/apk/*" - orphans="$(apk list --orphaned | awk '{print $1}' 2> /dev/null)" if [[ "$orphans" ]]; then orphans="$(printf "$orphans" | tr '\n' ' ')" @@ -45,6 +41,10 @@ fi script="$(dirname $(realpath $0))/conf.d/$(hostname).sh" [[ -x "$script" ]] && printf ""$font_colored"> executing script "$script"..."$font_default"\n" && (. "$script") +printf ""$font_colored"> cleaning cache..."$font_default"\n" +apk cache clean &> /dev/null +rm -rf "/var/cache/apk/*" + printf ""$font_colored_bold">> system updated finished!"$font_default"\n" [[ ! "$reboot" ]] && exit 0