fix(脚本): 修复分流查看域名错误判断

pull/1006/head
mack-a 2024-03-20 17:35:10 +08:00
parent 7383310cbe
commit bcdfb89601
1 changed files with 22 additions and 18 deletions

View File

@ -5874,15 +5874,16 @@ ipv6Routing() {
fi
fi
if [[ -f "${singBoxConfigPath}IPv6_out_route.json" ]]; then
echoContent yellow "sing-box"
jq -r -c '.route.rules[]|select (.outbound=="IPv6_out")' "${singBoxConfigPath}IPv6_out_route.json" | jq -r
elif [[ ! -f "${singBoxConfigPath}IPv6_out_route.json" && -f "${singBoxConfigPath}IPv6_out.json" ]]; then
echoContent yellow "sing-box"
echoContent green " ---> 已设置IPv6全局分流"
else
echoContent yellow " ---> 未安装IPv6分流"
if [[ -n "${singBoxConfigPath}" ]]; then
if [[ -f "${singBoxConfigPath}IPv6_out_route.json" ]]; then
echoContent yellow "sing-box"
jq -r -c '.route.rules[]|select (.outbound=="IPv6_out")' "${singBoxConfigPath}IPv6_out_route.json" | jq -r
elif [[ ! -f "${singBoxConfigPath}IPv6_out_route.json" && -f "${singBoxConfigPath}IPv6_out.json" ]]; then
echoContent yellow "sing-box"
echoContent green " ---> 已设置IPv6全局分流"
else
echoContent yellow " ---> 未安装IPv6分流"
fi
fi
exit 0
@ -6287,15 +6288,18 @@ showWireGuardDomain() {
fi
# sing-box
if [[ -f "${singBoxConfigPath}wireguard_out_${type}_route.json" ]]; then
echoContent yellow "sing-box"
jq -r -c '.route.rules[]' "${singBoxConfigPath}wireguard_out_${type}_route.json" | jq -r
elif [[ ! -f "${singBoxConfigPath}wireguard_out_${type}_route.json" && -f "${singBoxConfigPath}wireguard_out_${type}.json" ]]; then
echoContent yellow "sing-box"
echoContent green " ---> 已设置warp ${type}全局分流"
else
echoContent yellow " ---> 未安装warp ${type}分流"
if [[ -n "${singBoxConfigPath}" ]]; then
if [[ -f "${singBoxConfigPath}wireguard_out_${type}_route.json" ]]; then
echoContent yellow "sing-box"
jq -r -c '.route.rules[]' "${singBoxConfigPath}wireguard_out_${type}_route.json" | jq -r
elif [[ ! -f "${singBoxConfigPath}wireguard_out_${type}_route.json" && -f "${singBoxConfigPath}wireguard_out_${type}.json" ]]; then
echoContent yellow "sing-box"
echoContent green " ---> 已设置warp ${type}全局分流"
else
echoContent yellow " ---> 未安装warp ${type}分流"
fi
fi
}
# 添加WireGuard分流
@ -8773,7 +8777,7 @@ menu() {
cd "$HOME" || exit
echoContent red "\n=============================================================="
echoContent green "作者mack-a"
echoContent green "当前版本v3.2.31"
echoContent green "当前版本v3.2.32"
echoContent green "Githubhttps://github.com/mack-a/v2ray-agent"
echoContent green "描述:八合一共存脚本\c"
showInstallStatus