From 3c9869649d50cf5c5de99bf0de997d7ecdd08e7f Mon Sep 17 00:00:00 2001 From: "PC-202302260912\\Administrator" <1769111741@qq.com> Date: Mon, 7 Aug 2023 17:15:57 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/main.sh b/main.sh index 7f65187..b19403f 100644 --- a/main.sh +++ b/main.sh @@ -111,7 +111,7 @@ game_send_package() { restart_server "core" "$channel" fi else - awk '{print $2}' "txt/$channel" | while read -r ip; do + awk '{print $2}' "txt/$channel" | tr -d '\r' | while read -r ip; do unzip_package $ip $package $source_tar $destination_dir if [[ $reboot -eq 1 ]]; then restart_server "core" "$ip" @@ -130,7 +130,7 @@ gm_send_package() { if is_valid_ip "$channel"; then unzip_package $channel $package $source_tar $destination_dir else - awk '{print $2}' "txt/$channel" | while read -r ip; do + awk '{print $2}' "txt/$channel" | tr -d '\r' | while read -r ip; do unzip_package $ip $package $source_tar $destination_dir done fi @@ -269,7 +269,7 @@ gm_option() { restart_server "admin" "$ip" elif [ "$action" = "batch_reboot" ]; then local path="/data/update/script/txt/gm_ip.txt" - awk '{print $2}' "${path}" | while read -r ip; do + awk '{print $2}' "${path}" | tr -d '\r' | while read -r ip; do echo -e "开始更新gm $ip" restart_server "admin" "$ip" done