From d95694943b43100d675a1bce7c60f7ddcb2b8a47 Mon Sep 17 00:00:00 2001 From: Yawasau <229953100a@gmail.com> Date: Sun, 29 May 2022 00:47:58 +0800 Subject: [PATCH] bugfix --- tools/bin/tools.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/bin/tools.sh b/tools/bin/tools.sh index 5a6f6d1..d2e20b9 100644 --- a/tools/bin/tools.sh +++ b/tools/bin/tools.sh @@ -23,7 +23,7 @@ fi . "$bin_path/bin.sh" zipFile="$(ls -t /storage/emulated/0/Download/*.zip 2>/dev/null | head -1)" FILE_NAME="${zipFile##*/}" -if [[ $(unzip -l "$zipFile" | awk '{print $4}' | grep -oE "^backup_settings.conf$") != "" ]]; then +if [[ $(unzip -l "$zipFile" 2>/dev/null | awk '{print $4}' | grep -oE "^backup_settings.conf$") != "" ]]; then echoRgb "發現$zipFile\n移動並解壓縮中...." mv "$zipFile" "$MODDIR" update_script @@ -125,7 +125,7 @@ if [[ $json != "" ]]; then zipFile="$(ls -t /storage/emulated/0/Download/*.zip 2>/dev/null | head -1)" FILE_NAME="${zipFile##*/}" seconds=1 - while [[ $(unzip -l "$zipFile" | awk '{print $4}' | grep -oE "^backup_settings.conf$") = "" ]]; do + while [[ $(unzip -l "$zipFile" 2>/dev/null | awk '{print $4}' | grep -oE "^backup_settings.conf$") = "" ]]; do zipFile="$(ls -t /storage/emulated/0/Download/*.zip 2>/dev/null | head -1)" FILE_NAME="${zipFile##*/}" echoRgb "$seconds秒"