From 01bb9d7eca35bd7104bd6fbb6a329cb34be1cb40 Mon Sep 17 00:00:00 2001 From: Matteo Rossini Date: Wed, 12 May 2021 23:35:11 +0200 Subject: [PATCH] clean cache from packages without gpg signature --- src/slackpkgplus.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/slackpkgplus.sh b/src/slackpkgplus.sh index 1e27c6b..aa4911a 100755 --- a/src/slackpkgplus.sh +++ b/src/slackpkgplus.sh @@ -1826,6 +1826,11 @@ if [ "$SLACKPKGPLUS" = "on" ];then touch $WORKDIR/install.log fi + if [ -e $TEMP ];then + # clean cache from packages without gpg signature + find $TEMP ! -type d|sort|tac|awk '{if($1~/\.asc$/)f[$1]++;if($1~/\.t.z$/ && !f[$1".asc"])print $1}' |xargs -r rm -f + fi + if [ "$CMD" == "update" -o "$CMD" == "check-updates" ];then # answer to "Do you really want to download all other files" # if there are new changes