From da5c0c5d4e37ad16cd505aeca50da41bfb534776 Mon Sep 17 00:00:00 2001 From: Jensfrank Date: Tue, 2 Jul 2024 00:08:11 +0800 Subject: [PATCH] Update nodeloc_vps_autotest_speed.sh --- nodeloc_vps_autotest_speed.sh | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/nodeloc_vps_autotest_speed.sh b/nodeloc_vps_autotest_speed.sh index bbe18fd..ea68395 100644 --- a/nodeloc_vps_autotest_speed.sh +++ b/nodeloc_vps_autotest_speed.sh @@ -110,7 +110,7 @@ run_and_capture() { } # 去除三网测速板块板块ANSI转义码并截取 -process_speedtest_output() { +speedtest_process_output() { local input="$1" # 去除 ANSI 转义码并提取所需的测试结果 @@ -122,11 +122,6 @@ process_speedtest_output() { ' } -speedtest_process_output() { - echo "Debug: Calling speedtest process" >&2 - process_speedtest_output "$1" "多功能 自更新 测速脚本" -} - # 运行所有测试 run_all_tests() { echo -e "${RED}开始测试,测试时间较长,请耐心等待...${NC}" @@ -146,8 +141,8 @@ run_all_tests() { format_results() { # 处理三网测速结果 -local processed_speedtest_multi_result=$(process_speedtest_output "$speedtest_multi_result") -# local processed_speedtest_single_result=$(process_speedtest_output "$speedtest_single_result") +local processed_speedtest_multi_result=$(speedtest_process_output "$speedtest_multi_result") +local processed_speedtest_single_result=$(speedtest_process_output "$speedtest_single_result") result="[tabs] [tab=\"多线程测速\"] @@ -157,7 +152,7 @@ $processed_speedtest_multi_result [/tab] [tab=\"单线程测速\"] \`\`\` - +$processed_speedtest_single_result \`\`\` [/tab] [/tabs]"