From 0bfea0d7693fefb0250a47e1ebb011ffc80dabcd Mon Sep 17 00:00:00 2001 From: mack-a <57424792+mack-a@users.noreply.github.com> Date: Thu, 25 Jan 2024 11:13:12 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E8=84=9A=E6=9C=AC):=20=E4=BF=AE=E6=94=B9xr?= =?UTF-8?q?ay-core=20socks5=E5=85=A8=E5=B1=80=E3=80=81=E5=8D=95=E7=8B=AC?= =?UTF-8?q?=E5=88=86=E6=B5=81=E5=A4=B1=E8=B4=A5=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- install.sh | 23 ++++++++++------------- 1 file changed, 10 insertions(+), 13 deletions(-) diff --git a/install.sh b/install.sh index 2cdc974..58cd22f 100644 --- a/install.sh +++ b/install.sh @@ -6680,18 +6680,6 @@ setSocks5OutboundRoutingAll() { if [[ "${socksOutStatus}" == "y" ]]; then if [[ "${coreInstallType}" == "1" ]]; then - cat <${configPath}10_ipv4_outbounds.json -{ - "outbounds":[ - { - "protocol":"freedom", - "settings":{ - }, - "tag":"socks5_outbound" - } - ] -} -EOF rm ${configPath}09_routing.json >/dev/null 2>&1 fi if [[ -n "${singBoxConfigPath}" ]]; then @@ -6975,6 +6963,15 @@ setSocks5OutboundRouting() { fi fi done < <(echo "${socks5RoutingOutboundDomain}" | tr ',' '\n') + if [[ ! -f "${configPath}09_routing.json" ]]; then + cat <${configPath}09_routing.json +{ + "routing":{ + "rules": [] + } +} +EOF + fi routing=$(jq -r ".routing.rules += [{\"type\": \"field\",\"domain\": ${domainRules},\"outboundTag\": \"socks5_outbound\"}]" ${configPath}09_routing.json) echo "${routing}" | jq . >${configPath}09_routing.json fi @@ -8927,7 +8924,7 @@ menu() { cd "$HOME" || exit echoContent red "\n==============================================================" echoContent green "作者:mack-a" - echoContent green "当前版本:v3.1.38" + echoContent green "当前版本:v3.1.39" echoContent green "Github:https://github.com/mack-a/v2ray-agent" echoContent green "描述:八合一共存脚本\c" showInstallStatus