符号错误修正

This commit is contained in:
shenmo 2022-10-21 13:46:23 +08:00
parent 18db530c0d
commit a09425f361
2 changed files with 2 additions and 2 deletions

View File

@ -6,7 +6,7 @@ else
PKG_UPGRADE_LIST=`for PKG_NAME in $PKG_LIST;
do
#### 检测是否是hold状态
if [ "${dpkg-query -W -f='${Status}' $PKG_NAME | grep hold}" != "" ];then
if [ "$(dpkg-query -W -f='${Status}' $PKG_NAME | grep hold)" = "" ];then
echo "true"
echo "$PKG_NAME"
else

View File

@ -74,7 +74,7 @@ update_app_number=`echo ${update_app_number##*information...}`
PKG_LIST="$(bwrap --dev-bind / / --bind '/opt/durapps/spark-store/bin/apt-fast-conf/sources.list.d/sparkstore.list' /etc/apt/sources.list.d/sparkstore.list apt list --upgradable -o Dir::Etc::sourcelist="sources.list.d/sparkstore.list" -o Dir::Etc::sourceparts="-" -o APT::Get::List-Cleanup="0" | awk 'BEGIN {FS="/"} {print $1}' | awk NR\>1)"
for PKG_NAME in $PKG_LIST;do
if [ "${dpkg-query -W -f='${Status}' $PKG_NAME | grep hold}" != "" ];then
if [ "$(dpkg-query -W -f='${Status}' $PKG_NAME | grep hold)" = "" ];then
let update_app_number=update_app_number-1
fi
done